This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: fullname syntax variable for testsuite


On Thu, May 05, 2005 at 01:32:02PM -0400, Bob Rossi wrote:
> Hi all,
> 
> Hopefully this should make everyone happy. If the regex is slightly
> incorrect, after this patch, it should be simple to modify it and have
> the testsuite pick up on those changes.
> 
> As you will notice, the initial regex that Eli posted does not match the
> case d:foo. If it is desired to match this case up front, I can do that.
> Otherwise, it's noted in the comment, and can be changed when we run
> into the problem.

For Windows, don't you want the more specific version Chris posted?
  [a-zA-Z]:\\.*\|\\\\[^\\][^\\]*\\[^\\].*

Also, while I don't want to quibble about the regex more than necessary
right now, it should match the final slash in the path.  Either /.*/ or
\.*\ as the case may be.

> +# The variable fullname_syntax is a regexp which matches what GDB considers
> +# an absolute path. It is currently debatable if the windows style paths 
> +# d:foo and \abc should be considered valid as an absolute path.
> +# This regex matches \abc but not d:foo.
> +global fullname_syntax
> +if ![info exists fullname_syntax] then {
> +    set fullname_syntax "(\[A-z\]:)?\[/\\\\\].*"
> +}

Don't bother with the 'info exists' unless there's some need for it
that I'm missing.  Please capitalize Windows.

-- 
Daniel Jacobowitz
CodeSourcery, LLC


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]