<: cannot begin a template argument list

前端 未结 4 547
挽巷
挽巷 2020-12-14 19:07

I get an error <: cannot begin a template argument list on g++ compiler. Code

template class SomeClass;
class Class;

SomeClass<::Cla         


        
4条回答
  •  被撕碎了的回忆
    2020-12-14 19:26

    Try the following instead:

    SomeClass< ::Class>* cls;
    

    You can find more info in this question about digraphs. This question about trigraphs could be helpful also.

提交回复
热议问题