On 28/07/14 10:15, Felix Hartmann wrote:
name ~ '.*\(' { set name='${name|subst:"(=>"}'; echo "namehasbracket=1" }
name ~ '.*\)' { set name='${name|subst:")=>"}'; echo "namehasbracket=2" }
I looked at the code and the way the code currently is, the pattern
has to match the whole name. Eg you would need '.*\(.*' and '.*\).*'
but the second one would happen to match if the closing bracket was
at the end of the string which it probably is in many cases.
I found this surprising so I suggest that we change this so
that it will match anywhere in the string. That means that you
would just need '\(' to match an open parenthesis.
But this would not be entirely backward compatible, so it is up to
you guys as to whether it is worth doing or not.
..Steve
_______________________________________________
mkgmap-dev mailing list
[email protected]
http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev