The listener example still refers to Ref<> and shared pointers, but in
reality the generated method does not pass a shared pointer. The actual
signature looks more like this:
virtual void enterKey(ParserRuleContext * /*ctx*/) override { }
This change updates the example to match that signature, and removes a line
discussing Ref<>. It also adds the "override" keyword in order to make the
user's code a little more robust against typos/changes in the grammar.
In order to export generated classes in DLLs we need a way to specify the __declspec setting. This is is usually done via a macro that takes the import or export value. The new parameter (`-export-macro`) allows to specify this, which increases the flexibility of the generated classes.
The C++ target documentation has been extended to describe build specific things, includig this new parameter.
No need to use shared_ptr for management. Listeners are, like the other main classes (parser, lexer, input stream etc.) provided by the application and hence managed there.
In order to lower the overhead when passing around Token instances via smart pointers and because the ownership is clear (token streams own them), these instances can be passed as raw pointers.
- Avoiding double semicolons is tricky with the kind of rule nesting. Previous changes for that caused the tests to break as there were semicolons missing then.
- VS complained about the shift code generated using 1L as base, which is signed. Changed that to 1ULL, which is what is actually intended.
- Reverted the change to avoid a warning in RuleSempredFunction() in Cpp.stg as the fix didn't work 100%. We need a different solution.
- A few remaining changes had to be done for the C++ runtime tests which now completely pass.
- Added a runtime testing overview document.
- Added a description of C++ target.
- Updated the ANTLR release document.