in reply to Parse::RecDescent: problem with grammar and error reporting
Suggestion (untried):
That still allows text like:text: /[^@\n]*(?:\S@[^@\n]*)*/
I cannot deduce whether you want to allow that or not.foo bar@
It's not the most efficient regex, as it typically will backtrack one character on each (valid) @ character encountered. But since Parse::RecDescent is a massive backtracking engine written in Perl, this is likely to be acceptable.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Parse::RecDescent: problem with grammar and error reporting
by kikuchiyo (Hermit) on Jan 20, 2012 at 11:15 UTC | |
by JavaFan (Canon) on Jan 20, 2012 at 12:12 UTC | |
by kikuchiyo (Hermit) on Jan 20, 2012 at 12:44 UTC | |
by JavaFan (Canon) on Jan 20, 2012 at 13:18 UTC | |
by kikuchiyo (Hermit) on Jan 20, 2012 at 13:56 UTC |