Created
January 25, 2018 20:56
-
-
Save olegchir/01e53b94dcc96647c03ddb43abd3fdfd to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#pragma once | |
class FakeInt { | |
public: | |
FakeInt(int value) | |
: value(value) | |
{ | |
} | |
operator int() const | |
{ | |
return value; | |
} | |
template <typename T> | |
bool operator==(const T& other) const | |
{ | |
return true; | |
} | |
private: | |
int value; | |
}; | |
#define int FakeInt |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment