|
|
Home » U++ TheIDE » U++ TheIDE: CodeEditor, Assist++, Topic++ » C++ Parser
|
|
|
|
Re: C++ Parser [message #33943 is a reply to message #33942] |
Wed, 28 September 2011 23:27 ![Go to previous message Go to previous message](theme/default/images/up.png) ![Go to next message Go to next message](theme/default/images/down.png) |
|
mirek wrote on Wed, 28 September 2011 17:14 | Is it as fast as we need too?
|
I'm gonna find out (just built the newest version..)
|
|
|
|
Re: C++ Parser [message #34157 is a reply to message #33947] |
Tue, 25 October 2011 14:27 ![Go to previous message Go to previous message](theme/default/images/up.png) ![Go to next message Go to next message](theme/default/images/down.png) |
|
I did some further work on integration of clang and code editor. Here's the result ![Smile](images/smiley_icons/icon_smile.gif)
![index.php?t=getfile&id=3480&private=0](index.php?t=getfile&id=3480&private=0)
When I fix some bugs I will upload binaries here so everybody could see how it works.
I'm also trying to parse all the upp project functions/methods. When it's ready I'll publish the results about accuracy and speed of parsing. Anyway for now clang seems to be quite promising.
|
|
|
|
|
Re: C++ Parser [message #34161 is a reply to message #34159] |
Tue, 25 October 2011 17:53 ![Go to previous message Go to previous message](theme/default/images/up.png) ![Go to next message Go to next message](theme/default/images/down.png) |
Novo
Messages: 1363 Registered: December 2006
|
Ultimate Contributor |
|
|
mirek wrote on Tue, 25 October 2011 11:36 |
I believe that the real trouble is not C++ parser alone, working on single file, but how to make all files work together (with all macros and headers and such).
|
AFAIK, clang is a real compiler, so, it has to parse all included files. The difference with gcc is that internal data structure is more high level and it stores more info for each parsed element. As a result you can use it not just to jump/navigate among files but also to regenerate file back (or to do some refactoring and generate files after that). It is a real parser an you have real type info about each node. The only question is performance. But XCode is based on clang and seems to work fine.
Regards,
Novo
|
|
|
Re: C++ Parser [message #34162 is a reply to message #34159] |
Tue, 25 October 2011 18:48 ![Go to previous message Go to previous message](theme/default/images/up.png) ![Go to next message Go to next message](theme/default/images/down.png) |
|
Quote: | I believe that the real trouble is not C++ parser alone, working on single file, but how to make all files work together (with all macros and headers and such).
|
I had also #include <Core/Core.h> in the sample file and the speed was more than acceptable (especially the second time when files were cached by the system I guess). Besides clang supports precompiled headers what should make parsing fast enough even if lots of headers and macros are involved.
Integrating clang with upp is also very easy. It's only one file libclang.dll (4.7 MB) that has to be distributed with the rest of the framework.
Anyway I'll try to finish the demo and add the whole upp library with windows headers and see what the speed will be.
|
|
|
Re: C++ Parser [message #34163 is a reply to message #34160] |
Tue, 25 October 2011 18:52 ![Go to previous message Go to previous message](theme/default/images/up.png) |
|
fudadmin wrote on Tue, 25 October 2011 11:46 | I have been also working on the ide upp Cpp code parsing and browsing improvement alternative and also using GridCtrl .
|
That's a great news! Could you share your sources?
Quote: | I tried to use clang for compiling upp on mac but it didnt work. Are you able to compile upp with clang?
|
On win64 clang exploded during compilation one of the upp's package (I used svn version not a stable one). But I'll keep on trying ![Smile](images/smiley_icons/icon_smile.gif)
|
|
|
Goto Forum:
Current Time: Sun Jun 16 04:22:37 CEST 2024
Total time taken to generate the page: 0.02424 seconds
|
|
|