Created
July 16, 2014 10:31
-
-
Save gin0606/b88b7f3b5f34a0ec8fb6 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
| // Hoge::FugaEnumを前方宣言したい | |
| class Hoge : public TemplateClass<Hoge, FugaEnum> { | |
| public: | |
| enum class FugaEnum { | |
| FOO, | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
なんと、
C++11ならenumを前方宣言できます!が、内部列挙型
FugaEnumを前方宣言するには外部クラスHogeを完全に定義しなければいけないので、CRTPを適用することは(テンプレートとプリプロセッサの神様が物凄くトリッキーなことを考え付かなければ)できないのではないでしょうか?