c++ - Unknown type name class -
i have following header files:
https://gist.github.com/wemakeweb/5501443 , compiler reports "unknown type name class". have included forward declaration, break circular including , think have to. did forget?
edit: put in 1 header file, , compiler still reports "expected ; after top level declarator"
https://gist.github.com/wemakeweb/5583500
edit 2 im getting linker errors. "undefined symbols architecture x86_64"
solved, problems were
- circular including
- main.c instead of main.cpp
- the actual code in static lib not linked properly
this error? error: unknown type name ‘class’
you're compiling c rather c++.
make sure source file has .cpp
extension, , relevant compiler flags set correctly. (it helps if include exact error message , line numbers. don't try , retype, cut+paste.)
Comments
Post a Comment