>>> Ravikiran Rajagopal <ravi.rajagopal@...> seems to think that:
>[Removed cedet-devel as the following is semantic-specific.]
>On Monday 24 March 2008 07:03:08 pm Eric M. Ludlam wrote:
>> I've updated the scope calculator to find and use the
>> merged A namespace instead of only the namespace block that bar::xx
>> shows up in.
>Thank you; the simple test case works. However, I have a more complex case
>which does not work yet. Once I isolate the problem further, I will send you
>a new case. Should I regenerate all the cached databases after your last
The database files only contain the raw tags. Part of the analysis
step is to create a typecache that merges all known types into a
single searchable table. That table gets rebuilt whenever semantic
detects a change somewhere.
When in doubt, do this:
C-u M-x bovinate RET
to get all such caches flushed out.
>I have also been playing with gccxml which handles virtually every C++ parsing
>case I have thrown at it (better than Eclipse CDT, KDevelop, Visual C++ 2008
>Express) and produces very nice XML output which can be parsed very easily.
>The main drawbacks are that only instantiated templates are output and that
>incremental parsing is impossible. How difficult would it be to add a new
>back end (a la ebrowse) into semantic? Again, I am a novice at elisp but
>could whip up a python script fairly easily to massage the XML into virtually
>any sort of output.
[ ... ]
I've been reading about that, and hoping to try it out sometime.
The only restriction on a Semantic parser is that it can be done with
a single function that returns tags. The texi parser is a good
example. It's setup is like this:
'((parse-region . semantic-texi-parse-region)
(parse-changes . semantic-texi-parse-changes)))
If the gcc->xml->python->elisp cycle is fast, then an incremental
parser is likely still possible, even mixing the existing semantic
parser with the gcc one for full buffer parsing.
The first step would be an external script that creates something that
Emacs can call `read' on. There is a chapter in the semantic appdev
manual for Tag basics. It describes the output format.
The second step is to read in that stream, then 'cook' the tags into
something Semantic can create overlays for.
If that all works out, a script that builds database files for Emacs
to read in would be the bit that would really speed things up.
Eric Ludlam: eric@...
Siege: http://www.siege-engine.com Emacs: http://cedet.sourceforge.net