2188f5b37687ec2fc7a9519df9f260c41a447a40
[cparser] / TODO
1 Driver:
2
3 Refactoring:
4 - eliminate target_architecture.h and replace with stuff in lang_features.h
5 - create structures for variables and functions, removing the omnipotent declaration
6
7 Lexer:
8 - Add preprocessor code
9 - proper handling of different file encodings, parsing non-ascii strings
10 - We could save some space by holding source positions in a separate (somehow
11   compressed table) and only storing pointers to it on the AST.
12
13 Parser:
14 - disallow storage class specifiers in struct/union members
15 - label: declaration; is no valid C99 but we parse it anyway
16 - add constant folding code (optional, ast2firm already does it)
17 - Refactor code, so code to handle number values (and strings?) is an own
18   module and replacable
19 - Support some attributes. noreturn, unused, printf, scanf, packed would be
20   interesting candidates
21 - Add columns to source positions
22 - SourcePositions could be stored selectively on expressions that really need
23   them.
24 - check semantic for functions declared/defined in global scope and declared
25   again in a local scope
26 - print initialisation type_path for initializer errors
27 - check switches for: double cases, all enums
28
29 ast2firm:
30 - handle non-constant initializers
31 - output source file positions for panics...
32 - handle bitfield members with 0 correctly (standard says they finish the
33   current unit)
34
35 Missing Errors:
36 * check switches for double cases
37
38 Missing Warnings:
39 * dead assignments (int x = 5; x = bla(); -> dead assignment at x = 5;)
40 * unused label
41 * check switches for all enums values
42 * catch the if(k = b) cases, maybe require all assignments to be in parentheses
43   (but some few exceptions like toplevel, nested assignments)
44
45 Spec-Status:
46 (only test datasets tried yet)
47 164.gzip:    works
48 175.vpr:     works
49 176.gcc:     not ok
50 181.mcf:     works
51 186.crafty:  works (~though an asm is replaced with a stub)
52 253.perlbmk: not ok
53 254.gap:     not ok
54 255.vortex:  works
55 256.bzip2:   works
56 300.twolf:   works