It looks like you forgot a space.

But it's weird, because I can match (?<!// )#define but not (?<!//) #define.

Jean-Christophe 

> On Apr 16, 2018, at 7:35, F. Alfredo Rego <f.alfredor...@gmail.com> wrote:
> 
> I’m trying to find all “enabled” defines such as this:
> 
>     #define _some_enabled_define_
> 
> while excluding all “disabled” (commented) defines such as this:
> 
>     // #define _some_disabled_define_
> 
> 
> This regular expression causes BBEdit to include both of the above kinds of 
> defines (“enabled” defines and “disabled” (commented) defines) in the search 
> results:
> 
>     (?<!//)#define
> 
> As far as I believe, the forward slash is not a special character, but I 
> tried escaping it anyway:
> 
>     (?<!\/\/)#define
> 
> Same results.
> 
> 
> To test whether macOS supports a negative look-behind assertion, I tried an 
> obviously incorrect regular expression and got a reassuring error message 
> which tells me that, at least, the syntax for the negative look-behind 
> assertion is checked correctly:
> 
> <BBEdit_028.png>
> 
> 
> 
> 
> Am I missing something? Any clues?
> 
> Thanks.
> 
> Alfredo
> 
> 
> -- 
> This is the BBEdit Talk public discussion group. If you have a 
> feature request or would like to report a problem, please email
> "supp...@barebones.com" rather than posting to the group.
> Follow @bbedit on Twitter: <http://www.twitter.com/bbedit 
> <http://www.twitter.com/bbedit>>
> --- 
> You received this message because you are subscribed to the Google Groups 
> "BBEdit Talk" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to bbedit+unsubscr...@googlegroups.com 
> <mailto:bbedit+unsubscr...@googlegroups.com>.
> To post to this group, send email to bbedit@googlegroups.com 
> <mailto:bbedit@googlegroups.com>.
> Visit this group at https://groups.google.com/group/bbedit 
> <https://groups.google.com/group/bbedit>.

Jean-Christophe Helary
-----------------------------------------------
http://mac4translators.blogspot.com @brandelune


-- 
This is the BBEdit Talk public discussion group. If you have a 
feature request or would like to report a problem, please email
"supp...@barebones.com" rather than posting to the group.
Follow @bbedit on Twitter: <http://www.twitter.com/bbedit>
--- 
You received this message because you are subscribed to the Google Groups 
"BBEdit Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to bbedit+unsubscr...@googlegroups.com.
To post to this group, send email to bbedit@googlegroups.com.
Visit this group at https://groups.google.com/group/bbedit.

Reply via email to