>>> Jan Moringen <jan.moringen@...> seems to think that:
>Hi,
>
>I really like the new semantic include decoration. It is great to see
>whether the include path is set up correctly. However, the function
>semantic-decoration-include-visit does not work for me (at least when
>used in C++ source - the only thing I tried). I looked at it a bit, and
>I think the problem is that semantic-go-to-tag simply goes to the
>include tag itself, not the file referred to by the include. I changed
>the function to work for me and added simple error handling since it is
>interactive. Please let me know whether my change makes sense.
[ ... ]
Hi,
Thanks for the patch, and for pointing out that bug.
semantic-go-to-tag used to automatically move through include tags to
what they pointed at, but I had removed that recently because there
was no utility to go to the #include statement. I then replaced most
locations that depended on it the other way, and apparently missed
that one.
While looking into this, I discovered a couple inconsistencies in
include tag use, so I tried to tidy that up too. I checked my changes
into CVS.
Thanks
Eric
--
Eric Ludlam: eric@...
Siege: http://www.siege-engine.com Emacs: http://cedet.sourceforge.net

Hi,
I really like the new semantic include decoration. It is great to see
whether the include path is set up correctly. However, the function
semantic-decoration-include-visit does not work for me (at least when
used in C++ source - the only thing I tried). I looked at it a bit, and
I think the problem is that semantic-go-to-tag simply goes to the
include tag itself, not the file referred to by the include. I changed
the function to work for me and added simple error handling since it is
interactive. Please let me know whether my change makes sense.
Kind regards,
Jan

"Eric M. Ludlam" <eric@...> writes:
> I've changed the ctags installation procedure to be a bit more
> streamlined, and checked it into CVS.
Cool.
I'm getting an idle error:
CTAGS/config.h...
Idle Work Including Error: "#<buffer DsaCSSLConfig.C> - Wrong type argument: stringp, nil"
(I guess the actual filenames aren't significant, except that this is
ctags related.) config.h is the first file included into
DsaCSSLConfig.C.
I can't seem to debug this. If I set debug-on-error to t, I don't
seem to get any error (just "CTAGS/config.h...").
[...]

>>> "Matzi Kratzi" <matzikratzi@...> seems to think that:
>Would it be possible to use etags that comes along with gnu emacs?
[ ... ]
Hi,
Etags would be sufficient for finding a single tag by name in a
global flat namespace. Thus, if you wanted to find a function "foo",
etags could do it. The next step in smart completion, or showing
function hints is to go to the file the tag was found in, and have
Emacs parse it to get the extra needed information. The ebrowse
backend to semanticdb does something similar. Ebrowse does have a
little bit more info I can use though, such as the code
structure. (fields of a struct, etc).
There are some cute hacks out there that use etags and some
assumptions about how code is laid out to show function hints.
Semantic, however, needs the entire tag broken down into a data
structure which is uses to analyze the code for making suggestions.
Exuberent ctags includes signature, datatype, and other features. As
a side effect, I don't need Emacs to parse the file to use the tags,
and that is where the time savings comes in.
Eric
--
Eric Ludlam: eric@...
Siege: http://www.siege-engine.com Emacs: http://cedet.sourceforge.net

Howdy,
I've changed the ctags installation procedure to be a bit more
streamlined, and checked it into CVS.
The new configuration is in the various doc files, and there is
a single point for installing all the CTags support. You can do it
like this in your .emacs file:
(semantic-load-enable-all-exuberent-ctags-support)
It isn't in the default, because it will throw an error if there is
something wrong with your installed version of ctags.
Also in the mix, is language support for borne shell scripts,
supplied entirely by ctags. The sh script prototype was an experiment
to make adding support for a simple language like a shell script via
ctags very easy... It's 2 variables, and a 2 line function.
So if you are wishing there was support for some language that
happens to be supported by ctags, perhaps now you can add it.
See cedet/semantic/ctags/semantic-ectag-lang.el for the function
semantic-default-sh-setup.
Eric
>>> "Eric M. Ludlam" <eric@...> seems to think that:
>Hello all,
>
> Now in CEDET/CVS is an experimental ctags parsing database backend.
>I have only gotten support for C/C++ so far.
[ ... ]
--
Eric Ludlam: eric@...
Siege: http://www.siege-engine.com Emacs: http://cedet.sourceforge.net

Hello Eric
Desktop doesn't check value of function, that you provide to
desktop-minor-mode-handlers, so when it restore buffers, load is failed.
It's better to use dummy function, like this:
(defun my-desktop-ignore-semantic (desktop-buffer-file-name)
"Function to ignore cedet minor modes during restore of buffers"
nil)
With this function, all works fine
EML> Hi, I checked into CVS a small patch to semantic-util-modes which
EML> disables desktop for semantic minor modes. There is likely a better
EML> trick I could use instead of a disable, and to instead re-enable
EML> after semantic has been setup again. Perhaps someone who uses the
EML> desktop package can work on that?
EML> The new code is in semantic-util-modes.el in
EML> `semantic-add-minor-mode'.
--
With best wishes, Alex Ott, MBA
http://alexott.blogspot.com/http://xtalk.msk.su/~ott/http://alexott-ru.blogspot.com/

Hello
Thanks for patch, i'll check it tomorrow at work
On Sun, Oct 19, 2008 at 3:45 PM, Eric M. Ludlam <eric@...> wrote:
> Hi,
>
> I checked into CVS a small patch to semantic-util-modes which
> disables desktop for semantic minor modes. There is likely a better
> trick I could use instead of a disable, and to instead re-enable after
> semantic has been setup again. Perhaps someone who uses the desktop
> package can work on that?
>
> The new code is in semantic-util-modes.el in `semantic-add-minor-mode'.
>
> Eric
>
>>>> Alex Ott <alexott@...> seems to think that:
>>Hello
>>
>>In my setup, i first load all modes, and only after this i restore old
>>configuration with desktop, that loads files, registers, etc. May be when
>>restoring C++ source files, semantic initialisation is happened?
>>
>>>>>>> "EML" == Eric M Ludlam writes:
>> EML> Hi, Your patch makes some sense, but I have to wonder why these modes
>> EML> are starting up at all. They should only run if semantic-init-hooks
>> EML> are run, and that should only happen if a buffer is set up for
>> EML> parsing.
>>
>> EML> Do you know how Semantic gets into that state?
>>
>> EML> I don't use desktop, so have not encountered this issue.
>>
>> EML> Eric
>>
>> > Alex Ott <alexott@...> seems to think that:
>> >> Hello
>> >>
>> >> Some time ago i found, that cedet's routines break loading of desktop
>> >> file with errors like "Buffer ... wasn't set for parsing", etc. These
>> >> errors lead to stopping load of desktop file, so it doesn't restored
>> >> completely. Attached file add error handlers to some places, please
>> >> review it, and apply if all ok
>> >>
>>
>
> --
> Eric Ludlam: eric@...
> Siege: http://www.siege-engine.com Emacs: http://cedet.sourceforge.net
>
--
With best wishes, Alex Ott, MBA
http://alexott.blogspot.com/http://alexott-ru.blogspot.com/http://xtalk.msk.su/~ott/

Hi,
I checked into CVS a small patch to semantic-util-modes which
disables desktop for semantic minor modes. There is likely a better
trick I could use instead of a disable, and to instead re-enable after
semantic has been setup again. Perhaps someone who uses the desktop
package can work on that?
The new code is in semantic-util-modes.el in `semantic-add-minor-mode'.
Eric
>>> Alex Ott <alexott@...> seems to think that:
>Hello
>
>In my setup, i first load all modes, and only after this i restore old
>configuration with desktop, that loads files, registers, etc. May be when
>restoring C++ source files, semantic initialisation is happened?
>
>>>>>> "EML" == Eric M Ludlam writes:
> EML> Hi, Your patch makes some sense, but I have to wonder why these modes
> EML> are starting up at all. They should only run if semantic-init-hooks
> EML> are run, and that should only happen if a buffer is set up for
> EML> parsing.
>
> EML> Do you know how Semantic gets into that state?
>
> EML> I don't use desktop, so have not encountered this issue.
>
> EML> Eric
>
> > Alex Ott <alexott@...> seems to think that:
> >> Hello
> >>
> >> Some time ago i found, that cedet's routines break loading of desktop
> >> file with errors like "Buffer ... wasn't set for parsing", etc. These
> >> errors lead to stopping load of desktop file, so it doesn't restored
> >> completely. Attached file add error handlers to some places, please
> >> review it, and apply if all ok
> >>
>
--
Eric Ludlam: eric@...
Siege: http://www.siege-engine.com Emacs: http://cedet.sourceforge.net

Hello
In my setup, i first load all modes, and only after this i restore old
configuration with desktop, that loads files, registers, etc. May be when
restoring C++ source files, semantic initialisation is happened?
>>>>> "EML" == Eric M Ludlam writes:
EML> Hi, Your patch makes some sense, but I have to wonder why these modes
EML> are starting up at all. They should only run if semantic-init-hooks
EML> are run, and that should only happen if a buffer is set up for
EML> parsing.
EML> Do you know how Semantic gets into that state?
EML> I don't use desktop, so have not encountered this issue.
EML> Eric
> Alex Ott <alexott@...> seems to think that:
>> Hello
>>
>> Some time ago i found, that cedet's routines break loading of desktop
>> file with errors like "Buffer ... wasn't set for parsing", etc. These
>> errors lead to stopping load of desktop file, so it doesn't restored
>> completely. Attached file add error handlers to some places, please
>> review it, and apply if all ok
>>
--
With best wishes, Alex Ott, MBA
http://alexott.blogspot.com/http://xtalk.msk.su/~ott/http://alexott-ru.blogspot.com/

Hi,
Your patch makes some sense, but I have to wonder why these modes
are starting up at all. They should only run if semantic-init-hooks
are run, and that should only happen if a buffer is set up for
parsing.
Do you know how Semantic gets into that state?
I don't use desktop, so have not encountered this issue.
Eric
>>> Alex Ott <alexott@...> seems to think that:
>Hello
>
>Some time ago i found, that cedet's routines break loading of desktop file
>with errors like "Buffer ... wasn't set for parsing", etc. These errors
>lead to stopping load of desktop file, so it doesn't restored completely.
>Attached file add error handlers to some places, please review it, and
>apply if all ok
>

>>> Bruce Stephens <bruce+cedet@...> seems to think that:
>"Eric M. Ludlam" <eric@...> writes:
>
>> Now in CEDET/CVS is an experimental ctags parsing database backend.
>> I have only gotten support for C/C++ so far.
>
>You've got:
>
>(defcustom semantic-ectag-program "~/src/ctags-5.7/ctags" ; "ctags"
> "The Exuberent CTags program to use."
> :group 'semantic
> :type 'file)
>
>Probably "ctags" is the better default!
Heh, thanks for pointing that out.
>Also
>
>> (semantic-enable-exuberent-ctags 'c-mode)
>> (semantic-enable-exuberent-ctags 'c++-mode)
>
>doesn't work for me. The function only takes strings. (Presumably
>that's a bug. Not a significant problem, anyway.)
Thanks for pointing that out too. I had also discovered that late
this afternoon, and have checked in a fix.
>I get a background error with flymake-mode. I have flymake-mode
>configured so it doesn't operate on filenames with "flymake" in them,
>and semantic-inhibit-functions set appropriately to ignore the same
>buffers, but I saw errors when semantic was trying to run ctags on
>flymake files, so I guess semantic-inhibit-functions isn't being used
>properly for the new feature?
Hmmm. A curious issue. Those functions are run assuming the current
buffer is the buffer to be parsed. The ctags support specifically
does not load anything into a buffer, which is the main reason to have
made this extension. Thus, I can't use those functions.
According to the ctags, you can add --exclude="*flymake*", but I don't
know if that works when a file is explicitly listed, as this tool is
doing. In any case, you can put that into a ~/.ctags to try it.
Eric
--
Eric Ludlam: eric@...
Siege: http://www.siege-engine.com Emacs: http://cedet.sourceforge.net

"Eric M. Ludlam" <eric@...> writes:
> Now in CEDET/CVS is an experimental ctags parsing database backend.
> I have only gotten support for C/C++ so far.
You've got:
(defcustom semantic-ectag-program "~/src/ctags-5.7/ctags" ; "ctags"
"The Exuberent CTags program to use."
:group 'semantic
:type 'file)
Probably "ctags" is the better default!
Also
> (semantic-enable-exuberent-ctags 'c-mode)
> (semantic-enable-exuberent-ctags 'c++-mode)
doesn't work for me. The function only takes strings. (Presumably
that's a bug. Not a significant problem, anyway.)
I get a background error with flymake-mode. I have flymake-mode
configured so it doesn't operate on filenames with "flymake" in them,
and semantic-inhibit-functions set appropriately to ignore the same
buffers, but I saw errors when semantic was trying to run ctags on
flymake files, so I guess semantic-inhibit-functions isn't being used
properly for the new feature?
[...]

Hello all,
Now in CEDET/CVS is an experimental ctags parsing database backend.
I have only gotten support for C/C++ so far.
The parsing engine appears in the cedet/semantic/ctags directory.
When enabled, it works by using ctags to parse files not in an Emacs
buffer, and it uses the Emacs parser once a file is loaded into a
buffer. Ctags is a very fast parser, so offloading this parsing step
makes initial parsing of a project very fast.
It would be great if a few folks would give it a try, or even add a
some more language support.
To give it a try, do this:
1) Get the latest from CVS
2) Type: M-x semantic-enable-exuberent-ctags RET c-mode RET
OR add this to your .emacs file:
(semantic-enable-exuberent-ctags 'c-mode)
(semantic-enable-exuberent-ctags 'c++-mode)
This feature uses ctags to parse files on the fly, and does not read
in pre-parsed tag files, so there is no need do create TAGS files.
Let me know how it goes.
Enjoy
Eric
--
Eric Ludlam: eric@...
Siege: http://www.siege-engine.com Emacs: http://cedet.sourceforge.net

Hi,
I've updated semantic-ia.el with many more comments. Hopefully this
will help those interested in getting started programming utilities
with the Semantic analyzer easier.
As a bonus, `semantic-ia-fast-jump' will now preference
implementations of the destination tag instead of always jumping to
the first prototype it finds.
This uses the reference analyzer I had mentioned a couple weeks
back. It won't always work, so in those cases it should continue to
use the prototype.
I need to devise a way to get Semantic to find and parse more files.
I have a couple ideas, but welcome any new thoughts for anyone who
tries this, but still fails to jump to the desired implementation.
Enjoy
Eric
--
Eric Ludlam: eric@...
Siege: http://www.siege-engine.com Emacs: http://cedet.sourceforge.net