开发者

Egrep maximal repetition operator {,m} not working as expected?

Basically if I input a command such as egrep --color=ALWAYS "A{0,10}B" and then enter a string such as 'AAAAAB', this gives the desired behavior of being a match. However if I instead change it to egrep --color=ALWAYS "A{,10}B" it is no longer matching strings like the one I gave. In fact I have not been able to come up with a string that matches the one given. Is this unexpected behavior using the {,m} operator, or is my understanding of that operator not correct, as to me {0,10} should be the same behavior 开发者_如何学JAVAas {,10}. This is running on a bash shell with Ubuntu Linux 10.04

Thanks


Maybe an old bug? https://bugs.launchpad.net/ubuntu/+source/grep/+bug/460985

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜