about summary refs log tree commit diff stats
path: root/subx
diff options
context:
space:
mode:
authorKartik Agaram <vc@akkartik.com>2018-06-30 23:14:20 -0700
committerKartik Agaram <vc@akkartik.com>2018-06-30 23:14:20 -0700
commit1a3d4e2c73e86e6a905de60b1b80576e3d9f81c4 (patch)
treecd00eb844c8c4b7ea0ea3e3efa2338d72212b8f9 /subx
parent7b686a02ca508b9a414b96edfcff93a667354ac6 (diff)
downloadmu-1a3d4e2c73e86e6a905de60b1b80576e3d9f81c4.tar.gz
4301 - confirm that translation framework works
All tests continue to pass after a trivial translation phase.
Diffstat (limited to 'subx')
-rw-r--r--subx/022transform_immediate.cc8
1 files changed, 8 insertions, 0 deletions
diff --git a/subx/022transform_immediate.cc b/subx/022transform_immediate.cc
new file mode 100644
index 00000000..24a61f68
--- /dev/null
+++ b/subx/022transform_immediate.cc
@@ -0,0 +1,8 @@
+:(before "End One-time Setup")
+Transform.push_back(identity);
+
+:(code)
+void identity(const string& input, string& output) {
+  cerr << "running compiler phase\n";
+  output = input;
+}