Processing XML configuration which stores regular expressions and format strings for a documentation tool
Any idea on how to improve lookUp?


Use a concurrent cache.  The point is, regardless how good or bad you lookup function is, nothing beats a cache-hit performance wise..


  Is there a better way to do simple caching than using withDefault to
  mutate the underlying map?


getOrElseUpdate(key, value)