This patch introduces a new map type, compare. This map type can be
used to compare strings. Basic usage is like this:
Kcompare compare
And in a ruleset:
R$* $| $* $: $(compare $1 $@ $2 $: $)
RMATCH $#OK
R$* $#error
The map understands these arguments:
-a : string to return on successfull match (default MATCH)
-f : case sensitive search
-n : successfull return is if strings do NOT match
-T : string to return on unsuccessfull match (default blank)
If the map is called with only one string the following arguments are
relevant in this order
-z : delimiting charachter to seperate the key value into 2 strings
-k : string to use to seperate the key value into 2 strings
-v : string to use to seperate the key value into 2 strings
Currently, one can do something similar by storing the string into a
macro with a macro map and then by trying to match the LHS with it.
However that is a bit awkward and apparantly, more susceptible to
mangling.