File: TODO

package info (click to toggle)
nanopass-framework-scheme 1.9%2Bgit20160429.g1f7e80b-2
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 1,056 kB
  • sloc: makefile: 17
file content (48 lines) | stat: -rw-r--r-- 1,445 bytes parent folder | download | duplicates (9)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
TODO

Support:

1. Create Racket version of the nanopass framework

2. Extended to more R6RS libraries (at least if they support some form of
   compile time environment).

Nanopass Annoyances:

1. Removal of patterns is too strict matching EXACTLY the variable names (see 
   above example)  This may not be bad, but without the error is a very rough 
   edge.

2. Output forms need to match original language forms very closely, e.g. if we
   have:
   (define-language L
     over
     ---
     where
     (e in Expr
        (begin e0 ... e1)
        ---)
     ---)
   we cannot create the constructor:
   `(begin (set! ,x0 (var ,tmp*)) ...)

   because it sees this as a single form instead of a list.  Being able to
   create a make-begin helper for this situation is helpful, but ultimately
   we'd like it to match broader forms and complain at compilation time if it
   cannot prove they are safe itself.  The contortion we are instead forced to
   perform is:

   (let* ([expr* (map (lambda (x tmp) `(set! ,x (var ,tmp))) x0 tmp*)]
          [rexpr* (reverse expr*)]
          [last-expr (car rexpr*)]
          [expr* (reverse (cdr expr*))])
     `(begin ,expr* ... ,last-expr))

Features to add down the road:

1. Pass fusing with deforestation of the intermediate passes.

Error Handling/Loosening restrictions:

1. Fix parser to use positional information to report errors on the syntax
   error, in addition to reporting the error.