关键词:元编程;对象模型; GHC
摘 要:This thesis introduces {\it generalized arrows}, which are less restrictive than arrows in that they impose no containment relationship between the object language and metalanguage; this allows generalized arrows to be used for {\it heterogeneous} metaprogramming. This thesis also establishes a correspondence between two-level programs and one-level programs which take a generalized arrow instance as a distinguished parameter. A translation across this correspondence is possible, and is called a {\it flattening transformation}.