Re: search in file with regular expression
Re: search in file with regular expression
- Subject: Re: search in file with regular expression
- From: James Bucanek <email@hidden>
- Date: Tue, 27 Dec 2005 11:25:02 -0700
Dmitry Markman wrote on Tuesday, December 27, 2005:
>I tried to use the following pattern
>^[[:space:]]* (XCode 2.2)
>
>but xcode complains:
>Single File Find
>The regular expression "^[[:space:]]*" matches the
>empty string. Regular expressions for searches must
>not match the empty string.
>
>is it a bug or feature?
It's a requirement of the regex library the Xcode uses. As the error message explains, you can't use a regex that matches "nothing" or -- well -- it will.
>I just wanted to remove all leading spaces in some file
>bbedit did it without complain
^[[:space:]]+
... or use BBEdit. ;)
--
James Bucanek
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden