Parser + Classview Problems with current CVS
Roberto Raggi
raggi at di.unipi.it
Sat May 3 13:05:10 UTC 2003
On Saturday 03 May 2003 11:45, ErDroh wrote:
> I am using the current KDevelop from CVS (recompiled every day). In some
> projects i use nested namespaces, and i must see, that the classview had
> really problems with it. An small example:
>
> globalnamespace:
> |- sound
> |
> | |- CSoundEffect123
> | |-......
> |
> |- gfx
> |
> | |- CMesh123
> | |-......
> |
> |- script
> |
> | |- CAST
> | |-......
>
> (Everything with an C before his name is a Class). When I look at the
> classview i see following:
>
> globalnamespace:
> |- sound
> |
> | |- CSoundEffect123
> | |-......
> |
> |- gfx
> |
> | |- CMesh123
> | |-......
> |
> |- script
> |
> | |- CAST
> | |-......
>
> sound
>
> |- CSoundEffect123
> |-......
>
> gfx
>
> |- CMesh123
> |-......
>
> script
>
> |- CAST
> |-......
this is a very well know bug of the classbrowser+classstore(lib/sourceinfo)..
it will be fixed in future
>
> I dont think, that this is wanted. The next thing is the problem with
> preproccessor parsing. Another small example:
>
> class CFunnyClass
> {
> #if defined(__WIN32__) || defined(_WINDOWS)
> void asd();
> void qwertz();
>
> HWND hwnd;
> #elif defined(__linux__) || defined(linux)
> void asd();
> void qwertz();
>
> Window win;
> #endif
> }
>
> Now the preprocessor seems to stop (it dont exist in classview) and
> completion dont work anymore.
>
> I think, that this is a problem with the global defines, which are
> standard defines from gcc (the system-defines for example). They need to
> be inserted into the preprocessor from kdevelop by default.
>
you are right, the point is, the proprocessor doen't know the stardard GNU
defines.. a possible solution is to add to the project a fake header that
contains all these macros and ensure that the parser scans this header before
each file of the project..
this should be implemented with a new dialog in autoproject/trollproject where
you can add/edit this fake headers.
maybe, this could be useful, for cross development too
ciao robe
More information about the KDevelop-devel
mailing list