-
Notifications
You must be signed in to change notification settings - Fork 632
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
cxx: incorrect huge typeref values #1120
Comments
Heh... the problem here is that the file uses the preprocessor to generate statements and we don't have a real preprocessor. All I can do, probably, is refuse to emit types that contain too many tokens. Another thing we could attempt in the future would be to apply some preprocessing: capture macro names and either expand them properly (hard) or just replace them with a space (simple). It would probably fix this case. Obviously other cases with macros defined in different files would be still hopeless. |
The problem is that macros are skipped completely so here the cxx compiler thinks that
Trying to do macro expansion doesn't probably make sense indeed as they can be stored in another file. |
See #80. |
Is |
#1123 fixes this particular instance of bug. However a general fix for macros interference would be nice... it's just that I have no idea on how to do it. |
Do you agree with this milestone setting? |
It looks the compiler can get confused and here
https://github.com/universal-ctags/ctags/blob/master/parsers/cxx/cxx_tag.c#L323
it can generate tokens with huge strings. For instance, for
https://github.com/torvalds/linux/blob/master/lib/locking-selftest.c
I get typeref in one tag like
Other good files to try are these from the boost library:
Originally reported in #1111
The text was updated successfully, but these errors were encountered: