I'm not an expert on this. Before I answer that question, can you
explain why it would be useful to have possessive quantifiers in a
regexp matcher that does not backtrack?
I'm not sure if I understand what is the desired outcome as you've
unfortunately didn't provided what the expected output should be - as
I asked for. So I don't know if this is a solution to your task:
http://play.golang.org/p/3oHbx0EigU
If not, please provide the expected output you want.
Can you give a good example for its use? Your filename matching pattern is wrong: use [^/] instead of . after the "a".
That implies that the only possible use of a possessive quantifier in
a non-backtracking regexp implementation is to turn some matches into
failures-to-match. Is that correct?
To be clear, implementing this feature in Go's regexp package (if
possible) will have no performance implications.
http://play.golang.org/p/C0C1L01TX8
--
You received this message because you are subscribed to the Google Groups "golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.