Hi, Kaspar, Your solution is neat! I will take it!
Cheers, Li 在 2013-6-17,下午3:23,Kaspar Schiess <[email protected]> 写道: > I just dabbled with the bug in bracketed: > > def bracketed(thing, tag = false, left_bracket = '(', right_bracket > = ')') > thing = str(thing) if thing.kind_of? String > left = spaced(left_bracket) > right = spaced(right_bracket) > > if tag > return (left >> thing >> right) | thing > else > return (left >> thing >> right) > end > end > > The above will work a lot better and solve a few of the edge cases > you've been having. > > regards, > kaspar >
