in reply to Bug with finding all regexp matches
Is it a bug?
If you enable re 'debug', then you'll get to see what's going on in detail. The compiled regexes differ in much the way you'd expect:
Final program: Final program: 1: BOL (2) 1: BOL (2) 2: OPEN1 (4) 2: OPEN1 (4) 4: PLUS (6) 4: PLUS (6) 5: REG_ANY (0) 5: REG_ANY (0) 6: CLOSE1 (8) 6: CLOSE1 (8) 8: OPEN2 (10) 8: OPEN2 (10) 10: PLUS (12) 10: PLUS (12) 11: REG_ANY (0) 11: REG_ANY (0) 12: CLOSE2 (14) 12: CLOSE2 (14) 14: OPEN3 (16) 14: OPEN3 (16) 16: PLUS (18) 16: CURLYX[2] {1,3276 +7} (24) 17: REG_ANY (0) 18: REG_ANY (19) 19: CURLY {0,1} (23 +) 21: EXACT <z> (0) 23: WHILEM[1/1] (0) 24: NOTHING (25) 18: CLOSE3 (20) 25: CLOSE3 (27) 20: EOL (21) 27: EOL (28) 21: EVAL (23) 28: EVAL (30) 23: OPFAIL (24) 30: OPFAIL (31) 24: END (0) 31: END (0)
Comparing the traces is harder.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Bug with finding all regexp matches
by Anonymous Monk on Oct 15, 2016 at 18:12 UTC | |
by Anonymous Monk on Oct 15, 2016 at 18:18 UTC | |
by Anonymous Monk on Oct 15, 2016 at 19:07 UTC | |
by dave_the_m (Monsignor) on Oct 15, 2016 at 21:02 UTC | |
by Anonymous Monk on Oct 15, 2016 at 21:40 UTC | |
|