Created
March 29, 2014 20:36
-
-
Save EricWF/9862440 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
enum class my_big_enum | |
{ | |
/* imagine this changes a lot */ | |
}; |
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
#include "stores_enum.hpp" | |
// we actually need the fields here. | |
#include "enum.hpp" | |
void stores_enum::method_that_uses_enum() | |
{ | |
m_e = my_big_enum::value; | |
} |
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
// no need to include enum.hpp, we don't use it here | |
// We can just re-declare it. | |
enum class my_big_enum; | |
struct stores_enum | |
{ | |
void method_that_uses_enum(); | |
my_big_enum m_e; | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment