>>>>> "W" == Wilbert Berendsen <wbsoft / xs4all.nl> writes:

W> (update 12-06-2001:) Another question: even when using a ruby array for
W> the map (because of the order), will the regexp match the joined keys in
W> the same order? Won't the '<' be found before the '<<'?

 '<<' found (in your regexp) before '<'


W> But will it always be guaranteed that the keys in the regexp are matched
W> on a base of 'first one found matches'?

 actually yes (it's like a P language)

 here your regexp

pigeon% ruby -rjj -e '/\\>|\\<|<<|>>|<|>/.dump'
Regexp `\\>|\\<|<<|>>|<|>'
  0     on_failure_jump         ==>   3
  1     exactn "\>" (2)
  2     jump_past_alt           ==>   5
  3     on_failure_jump         ==>   6
  4     exactn "\<" (2)
  5     jump_past_alt           ==>   8
  6     on_failure_jump         ==>   9
  7     exactn "<<" (2)
  8     jump_past_alt           ==>  11
  9     on_failure_jump         ==>  12
 10     exactn ">>" (2)
 11     jump_past_alt           ==>  14
 12     on_failure_jump         ==>  15
 13     exactn "<" (1)
 14     jump                    ==>  16
 15     exactn ">" (1)
 16     end
pigeon% 


Guy Decoux