#993 PLCgen: First steps in cleaning up the generator backdoor communication
This patch removes the name generator and type generator as proper generators and instead passes them into other generators through their constructor.
At least eventually (I am not sure that holds right now) this could also be done when the other generators are called to do their computations but we aren't there yet, and at construction time has the advantage that they can be stored in a private final
field.
- Readable by commit.
- Name generator change is change is tricky int the transition generator test. The generators must be created in the target as that handles inter-generator communication, but the transition generator is also needed 'outside' since each test directly calls that generator instead of going through the normal processing.
- Split the change in 2 steps, which seems good enough.
- Type generator change was straightforward then.
- Type generator stores its results rather than communicating them to the code storage.
After pushing however I found that code-storage also use the type generator so copying the type generator results just before the call to code storage is technically not safe. - The type generator results are copied at the appropriate time to the code storage.
End-user visible changes:
- The order of the declarations in the generated code may be different.
Addresses #993
Edited by Dennis Hendriks