[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: [TSVN] C# regex (Was: [TSVN] Autocompletion list in the commit dialog)

From: SteveKing <steveking_at_gmx.ch>
Date: 2005-02-18 18:51:34 CET

Peter Mounce wrote:
> A start on a CSharp regex (I'm quite the novice when it comes to regex),
> built with a tool that uses the .NET regex library:
>
> (NOCASE) .cs =

Is C# really case insensitive about variable names and keywords like
'public', 'protected', ...?

> (?:public|protected|private)\s+((\w+[\.]+)*(\w+)\s+)+(\w+)

A test with this on some test C# files I have lying around shows that it
also matches e.g. 'class', 'void', 'this', ...
This is definitely not something we want in the autocompletion.

> There are issues with it. It's a first attempt. It's probably quite
> naively done, too. It benchmarks to about 40s per 1000 times against a 40Kb
> class file with ~100 members.
>
> The test tool: is the output that's put in the textbox going to all be added
> to the autocompletion list? Or is it more raw than that? If it's
> outputting the groups (I'm hazy on the terms here) of each match, can those
> be indented a couple spaces to separate them out a bit?

Every string you see in the output window (except the empty lines) are
added to the autocompletion.
And no, we won't change those matches. I mean we're using regexes here
so we don't have to do that.

> Can you change the test tool so it's resizable, please?

It's just a test tool!

But I've just uploaded a new version of it which doesn't print the empty
lines anymore.

Stefan

-- 
        ___
   oo  // \\      "De Chelonian Mobile"
  (_,\/ \_/ \     TortoiseSVN
    \ \_/_\_/>    The coolest Interface to (Sub)Version Control
    /_/   \_\     http://tortoisesvn.tigris.org
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tortoisesvn.tigris.org
For additional commands, e-mail: dev-help@tortoisesvn.tigris.org
Received on Fri Feb 18 18:52:15 2005

This is an archived mail posted to the TortoiseSVN Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.