TEAM-ADA Archives

Team Ada: Ada Programming Language Advocacy


Options: Use Forum View

Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Matthew Heaney <[log in to unmask]>
Reply To:
Matthew Heaney <[log in to unmask]>
Sat, 23 Jan 1999 19:35:15 -0800
text/plain (26 lines)
Daniel Wengelin <[log in to unmask]> writes:

> I have downloaded Emacs 20.2.1 and emacs-ada-mode 2.23.
> I am having problems with the Xref function. When I try to Goto Declaration of
> something, I often get the message "file C doesn't exist". It appears as if it
> only runs into trouble when the file the declaration is in has been prefixed
> with a full path by gnatf. I even get the feeling that the C in the above statement
> is the disk, as in C: (I edited the .xrb file and found that I could set it to W or anything)

I find that by changing the regex to include a colon, it successully
parses the dir/filename string preceeded by a diskname and colon.

(re-search-backward "^\\(%%\\|--\\) \\([a-zA-Z0-9\\:\\._/\\-]+\\)"

(You have to escape the colon with a pair of backslashes.  I'm not sure
why, since Info is telling me a colon is not a metacharacter.)

Take a peek in the xref file.  Are the filenames always preceeded by a
(capital letter) diskname and colon?  If so, then the following regex
will work too:

(re-search-backward "^\\(%%\\|--\\) \\([A-Z]:[a-zA-Z0-9\\._/\\-]+\\)"