computer science: Program Transformation
Perm url with updates: http://xahlee.org/cmaci/notation/pattern_matching_vs_pattern_spec.html
Discovered several languages. TXL, Colm, and the concept of program transformation.
There's the concept of Program transformation. Basically, it takes a input source code and transforms by some spec into another form. Similar to the concept of compiler, but more at textual level, i think. e.g. Source-to-source compiler.
There seems to be quite a few such languages. Here's a big list: http://www.program-transformation.org/Transform/TransformationSystems.
TXL (programming language) (home at http://www.txl.ca/) seems to be a popular transformation language. And a new supposedly improved one is Colm, at: http://www.complang.org/colm/. On the colm site, it has a Ph D thesis in PDF that gives a nice overview of such systems.