XML Language Definition -> Regular Expression -> LookBehind

SyntaxEditor for Windows Forms Forum

Posted 20 years ago by Filipe Batista - Software/Hardware Developer, Cristaltec spa
Avatar
Hi,

It seems that setting LookBehind with ^[ \f\t\v\x85]* in ExplicitPatternGroup it should match with :

"{begin of line}PatternValue", "{begin of line}{anyof [ \f\t\v\x85] zero or more}PatternValue".

but it doesn't match "{begin of line}PatternValue".


Have some ideas?


Filipe Batista
filipebatista@vodafone.pt

Comments (1)

Posted 20 years ago by Actipro Software Support - Cleveland, OH, USA
Avatar
Currently LookBehind, LookAhead, and PatternValue require that at least one character be consumed for a match to occur. Since you have a * in your LookBehind, it has a chance that it will not return a match. You could probably move the look-behind to the main PatternValue expression and use the regex look-behind syntax there. See the documentation on what that syntax is.

We are going to be working on improving this in the future so that zero-width patterns can be matched in LookBehind and LookAhead.


Actipro Software Support

The latest build of this product (v25.1.0) was released 25 days ago, which was after the last post in this thread.

Add Comment

Please log in to a validated account to post comments.