- Cleaned up emit() method
- New test case hashes inserted for entryPoint test code
Test cases
- Updated `simple_function_decls.t` to be exactly that, ONLY declarations with basic bodies
- Migrated advanced function usage testing code to a new unit test: `simple_functions.t`
DGen
- Updated function parameter symbol lookup to use new `symbolLookup9Entity)` mechanism
Test cases
- Updated test case `simple_function_decls.t` to use arguments referencing for tests
- Bug fix (#57) - Undid hack (of #46) for Context setting of VariableStdAloneAssignments
- Bug fix (#54) in VariableExpression whereby global lookups failed because they used `resolveWithin()` and not `resolveBest()`
Resolution
- Implemented `generateNameBest(Entity)` which can generate the full absolute path of the given Entity
- Added debug statements to `isDescendant(Container, Entity)`
- Added a TODO for when isDescendant fails, the asserts should be removed and placed there
Mapper
- The `symbolLookup()` method now takes in only the Entity and provides a hash (by making use of `generateNameBest()`)
DGen
- Switched to using the new `symbolLookup(Entity)` in `transform()` wherever it was being used
Test cases
- Updated test case `simple_function_decls.t` to use a global variable reference in a VariableExpression to test the fix for #54
- Make the name of the function const and public for FuncCallInstr
CodeEmitter
- Added methods `getCursor()`, `getSelectedQueueLength()` and `getQueueLength()`
- Removed old queue-specific methods
DGen
- Added emitting for FuncCallInstr instruction (function call support)
- Now emit globals first BEFORE function definitions
- Added debug prints per instruction to know what instruction is currently being transform()'d
- After emitting sections add newlines between each to make for neater C code
- `emitEntryPoint()` now adds a test for `simple_function_decls.t` (This should be removed soon)
- Removed incorrect TODO in `finalize()`
Dependency
- Make the `nodePool` static, to ensure pooling carries over across multiple `DNodeGenerator` instances
- Fixed handling of function calls in `expressionPass()` - do NOT add a so-called `FunctionDefNode` (remember functions are defined by `addFuncDef()`)
- Set the Context of standalone variable assignments to the Context of the Variable entity representing the variable being assigned to
TypeChecker
- Assign the Context object stored in the `FunctionCall` statement to the `FuncCallInstr`
Test cases
- Updated test case `simple_function_decls.t`
- Added newline to release info print
- Fixed module docstring
Commands
- Added new command-line options: `syntaxcheck`, `typecheck`
- Added todo to `help` command
- Re-ordered commands for order of appearance in help text
Compiler
- Added docstring to `beginCompilation(string[])` function
Mapper
- Added debug print of the Container being used for the symbol lookup
CodeEmitter
- Re-worked CodeEmitter class to use a single so-called "selected queue"
- Added methods to move back and forth between said "selected queue", get the length, etc.
- Remove old queue-specific methods
DGen
- Use the new CodeEmitter "selected-queue" functionality
- Emit function definitions now supported
Exceptions
- Added this keyword
Check
- Added support for SymbolTYpe.OCURLY and SymbolType.CCURLY to `getCharacter(SymbolType)`
Data
- Added a `hasParams()` method to the Function entity type
TypeChecker
- Added support for emitting function definitions (required DNode.poes = [] (cleaning), codeQueue cleaning etc.)
- Added `getInitQueue()` method to make a copy of the current "scratchpad" `codeQueue`
- Build up a copy of the global queue now (make a copy similiar to what we did for `getInitQueue()` but inline)
- Added a debug print
Dependency
- Added a FIXME note for issue #46
- Added a TODO relating to `static DNode[] poes`
Test cases
- Added test case `simple_function_decls.t` to test function definition code emit
- Updated test case `simple_variables.t` to note that the T code generates invalid C code
README
- Build instructions now generate coverage files (`.lst`s)
- Updated link to documentation