-
Notifications
You must be signed in to change notification settings - Fork 13
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
Question regarding preprocessor directives #17
Comments
Hi @JakeSays, Thanks for showing interest in this project. I'm afraid the C++20 frontend is not ready for writing such tools. I recently started to work on the type checker and the semantic passes required to correctly parse modern C++ code. As soon as I'm done with the type checker I will try to expose a set of APIs to use the preprocessor, the parser and the code model in C++ and JS apps. |
Ah ok. I thought this was a continuation of the one that was used in qt creator. Is that version available somewhere? I looked for it in the creator repo but I couldn't find it. Also I would be interested in writing a c# binding for this project when you get to that point. |
Yeah, modern C++ is considerably different than the versions of C++ I implemented in the past so I thought it was easier to start from scratch. You can find the Qt Creator C++ parser in these two directories but I don't know if you can still compile it as a standalone library. https://github.com/qt-creator/qt-creator/tree/master/src/libs/3rdparty/cplusplus |
I see there is a file named: https://github.com/robertoraggi/cplusplus/blob/main/src/cxx/preprocessor.cc which I see is a preprocessor. Good work! |
@asmwarrior yes, the preprocessor is almost complete but I still need to add APIs to abstract the file system access and configure the predefined macros and the system include paths. |
Hello,
I am thinking about using cplusplus to write some personal source analysis and transformation tools. The first one i want to implement is a simple file dependency analyzer.
Is this possible? At first glance it doesn't appear that the include directives are preserved. Am i missing something?
For me the value of your project is in a lighter libclang (like about 50 tones lighter) for analysis purposes.
The text was updated successfully, but these errors were encountered: