I need to recognize some special keywords in my app. I usually accomplish this task with a regex construction like this…
Expand|Select|Wrap|Line Numbers
- \bkeyword\b
This time I need to NOT allow a keyword to be matched if it is preceded or succeeded by a $ character, but unfortunately the damned regex engine considers the $ a non-alphanumeric character, so the above construction doesn’t work. I found the next regex construction as a workaround for my problem…
Expand|Select|Wrap|Line Numbers
- ([\W-[\$]]|\A)keyword([\W-[\$]]|\z)
Is there any way I can modify the alphanumeric \w and non-alphanumeric \W classes so I can make the $ character an alphanumeric one and then keep using the stylish \b escape for my needs?
Thanks in advance.