I've decided to implement pythonsPython's any
in C++. I've gone about this using templates to allow multiple types of data to be passed, instead of overloading the function multiple times. This is my first time using templates so I would really like feedback about my usage of them. I'm also fairly new with references and pointers, so I would like some criticism about my use of them as well. Of course, anything else is on the table and appreciated.
Note: While writing this program, I realized std::any_of
existed. So yes I do know there's already a built-in method for this. While writing this program, I realized std::any_of
existed. So yes, I do know there's already a built-in method for this.
Any.hppany.hpp