Worker Wrapper Splitting

Stratego -- Strategies for Program Transformation
The worker-wrapper component of the Stratego optimizer splits strategy definitions into a wrapper performing a pattern match, and a worker doing the real work of the operator. That is, a definition of the form
  f(as1 | as2) = {xs : ?t ; s}
is split into the pair of definitions
  f(as1 | as2) = {xs : ?t ; g(as1 | as2, xs)}
  g(as1 | as2, xs) = s
Thus f is reduced to a small definition comprising only a match and a call to the continuation g. The smaller definition for f becomes attractive to inline, especially in the context of a choice where pattern match compilation may integrate it with other matches, or in the context of a build, which may cancel against the match ?t.

-- EelcoVisser - 17 Aug 2003