cppclean
cppclean copied to clipboard
parsing error: (Token(u'::', xxx, yyy), [], [Token(u'B', zzz, bbb)])
Hi,
If I put the namespace as a Macro instead of 'using' or any other C++ way, it compiles but 'cppclean' fails to parse the tokens.
Here is a way to reproduce it:
#define NS_B(b) A::b
namespace A{
namespace B{
class C;
}
}
class C {
NS_B(B)::C* c;
};
In my opinion 'cppclean' should handle that situation. Just as C++ persist to backward compatibility to C language.
I have a large project (I can not share it) and I found a file where cppclean stops with an exception:
../cppclean/cppclean cppclean-error.cpp cppclean-error.cpp: parsing error: unexpected token: Token(u'return', 128, 134)
I deleted as much code as possible until the error disappeared, this is the result: cppclean.zip