summaryrefslogtreecommitdiff
path: root/miniany/REQUIREMENTS
diff options
context:
space:
mode:
Diffstat (limited to 'miniany/REQUIREMENTS')
-rw-r--r--miniany/REQUIREMENTS25
1 files changed, 24 insertions, 1 deletions
diff --git a/miniany/REQUIREMENTS b/miniany/REQUIREMENTS
index 0a6076c..645bdfa 100644
--- a/miniany/REQUIREMENTS
+++ b/miniany/REQUIREMENTS
@@ -59,4 +59,27 @@ not implementing:
you have a grammatical construct to help recognizing it.
- register number for register alloation
https://en.wikipedia.org/wiki/Strahler_number
-
+- volatile: we are not doing any optimizations for now, so volatile (as const)
+ can just be a ignored keyword.
+- c4 freestanding
+ - uses some casts, the malloc ones are actually good for clarification,
+ the ones in memset are not so usefull (this is all because we don't
+ have 'void *')
+ - open/read/close is POSIX, we would prefer either C style file handling
+ (we have it in libc-freestanding.c or some stdin, stdout thingy)
+ - again printf and varargs, either use libc-freestanding.c or revert to
+ putint, putstring, putnl..
+ - if (tk == '(') next(); else { printf("%d: open paren expected\n", line); exit(-1); }
+ =>
+ error("open paren expected"); }
+ - printf("%d: compiler error tk=%d\n", line, tk); exit(-1);
+ - printf("could not malloc(%d) symbol area\n") => remove size, also map to error
+ - printf("read() returned %d\n", i); => dito
+ - we also print a non-sensical line, but we don't really care about this
+ - printf("%d: bad enum identifier %d\n", line, tk); he number 'tk' looks like
+ debug output here, so we drop it.
+ error1int is the other option (also choosen in other places)
+ - other cases translate by hand:
+ - case EXIT: /* putstring("exit("); putint(*sp); putstring(") cycle = "); putint(cycle); putnl(); */ return *sp;
+ - default: putstring("unknown instruction = "); putint(i); putstring("! cycle = "); putint(cycle); putnl(); return -1;
+