Design Issues ---------------------------------------------------- * Create SourceCode class and make every JConstructor, JMethod, JVariable etc. an instance of it. That way there is a unified way to add comments to any piece of emitted source code. class SourceCode a where sourceAddComment :: (Show b) => a -> b -> a Lexer ---------------------------------------------------- * Handle escaped \:\) in semantic actions * replace '(:' with '.)' in order to be comply with Coco\R CSA ---------------------------------------------------- * in Java we can only have one out Attribute, so be sure to check this when parsing! TILING ---------------------------------------------------- * Throw assertion error in tile() instead of: 'System.err.println("ERROR: Encountered undefined node: " + n.kind() );' CODE GENERATION ---------------------------------------------------- * Provide more cues as comments in the generated code in order to aid the user while pin pointing bugs in semantic actions to actually generated code. Grammar ---------------------------------------------------- * How should we indicate start productions? There are several possibilities: - Do it as in Coco/R where the identifier used after the "COMPILER" keyword is re-used in the productions to indicate the start symbol - Do it as the CUP Parser Generator for Java (see http://www.cs.princeton.edu/~appel/modern/java/CUP/) does it: 'start with program;' -> Status Quo: the first production is used as the start symbol. PROS: No new keywords must be defined. CONS: Rule order is matters for the first production. Testing ---------------------------------------------------- * The only testing we do is to run a few grammars through hburg when running the test Cabal 'target'. That is obviously not enough. We should either use HUnit or Quickcheck in some sensible way to make sure that the correct parse errors and type errors are found and reported.