From f9ee5610093956e7323f68c4918345515b72ece6 Mon Sep 17 00:00:00 2001
From: Alan Schmitt <alan.schmitt@polytechnique.org>
Date: Tue, 2 Feb 2016 11:30:15 +0100
Subject: [PATCH] todo

---
 generator/Makefile |  1 +
 generator/TODO     | 32 +++++++++++++++++++++++++++++++-
 2 files changed, 32 insertions(+), 1 deletion(-)

diff --git a/generator/Makefile b/generator/Makefile
index ab2714b..b11cfd7 100644
--- a/generator/Makefile
+++ b/generator/Makefile
@@ -101,6 +101,7 @@ tests: $(ML_TESTS:.ml=.log.js) $(ML_TESTS:.ml=.token.js)
 
 tests/lambda: tests/lambda/Lambda.log.js
 tests/jsref: tests/jsref/JsInterpreter.log.js
+tests/jsrefunlog: tests/jsref/JsInterpreter.unlog.js
 
 clean_stdlib:
 	rm -f $(STD_DIR)/*.cmi
diff --git a/generator/TODO b/generator/TODO
index 0d40a90..fc05b7a 100644
--- a/generator/TODO
+++ b/generator/TODO
@@ -1,4 +1,6 @@
+- deal with unsupported let record in jsinterpreter.ml
 
+- cases seem to be in reversed order, check and fix
 
 - untab closing bracket for fun def
 
@@ -6,4 +8,32 @@
 
 - understand spec of polymorphic equality (= vs ===)
 
-- {type: "()"} devrait être "unit"
\ No newline at end of file
+- {type: "()"} devrait être "unit"
+
+- Choose a small example
+
+    var x = 3;
+    x = 4;
+    if (x === 4) {
+      while (true) {}
+    }
+
+- write a JS function that takes an esprima AST as input (sub-language for the
+  moment) that generates an AST in our syntax (encoded of concrete types):
+    { type : constructor; label0 : value ; … }
+  this should remember locations
+
+- edit JsSyntax.ml to put readable labels
+
+- write a driver in JS
+  - take a program in the text area
+  - parse to esprima
+  - translate to our syntax
+  - call JsInterpreter.js using the correct function (see run_js.ml)
+
+- translate stdlib.ml into stdlib.js
+
+- change constructors to functions, and generate nicer looking JS code for
+  these functions
+
+- correct the Makefile to make sure we do not generate everything all the time
\ No newline at end of file
-- 
GitLab