Is there a REX Designer such as expresso for grep?

scott.mcquilkin
Posts: 9
Joined: Mon Jan 29, 2007 11:45 am

Is there a REX Designer such as expresso for grep?

Post by scott.mcquilkin »

This would really be helpful for creating REX expressions, since they are not fully compatible with GREP.
User avatar
John
Site Admin
Posts: 2623
Joined: Mon Apr 24, 2000 3:18 pm
Location: Cleveland, OH

Is there a REX Designer such as expresso for grep?

Post by John »

No there isn't. A couple rules of thumb that will help creating REX expressions:

rex -x will dump an English version of the expression if you have the full Texis product

It can be helpful to anchor the expression to ensure directionality, particularly when using negative expressions ( ! or [^ )

It is deterministic and greedy, it does not backtrack to complete a match.

Repetition operators apply to the string since the last repetition operator, not just the preceding character.
John Turnbull
Thunderstone Software