On Fri, February 18, 2005 10:08 am, Josha Foust said:
>> Here is my VB6 expression setup to not match properties anymore:
>> (MULTILINE) .bas, .frm, .cls = ^\s*(?:(?:Public (?:Default )?|Private
>> )?(?:Sub|Function) ?)(\w+)\(|^Attribute VB_Name = "(\w+)"
>>
>> I would like to put a $ at the end of the attribute part, but it doesn't
>> seem to work. Heck, even ^A.*$ in multiline mode doesn't match
>> anything.
>> And ^.*$ locks up, even on a small file.
>>
>> Josha Foust
>>
>
> To reply to myself; has anyone gotten $ to work at matching the end of a
> line in MULTILINE mode? It happens with the latest test tool and TSVN
> nightly.
Yes, the .vb regex I wrote uses it, seemingly successfully, although I did
hit a problem where [ab$] was not matching a or b or line end as expected
so I had to use ([ab]|$).
Ah, I've just remembered that it also seems to put a whitespace character
(presumably \r) just before the $. Try capturing \s*$ instead of just $.
e.g. capturing (.{5})$ returns what look like groups of 4 characters.
I always forget if . captures \r\n but that might also explain your lack
of capture results for ^A.*$
Hope that helps.
Douglas
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tortoisesvn.tigris.org
For additional commands, e-mail: dev-help@tortoisesvn.tigris.org
Received on Fri Feb 18 19:26:55 2005