Rework renaming columns in | timechart #94
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fixes #92 .
Moved renaming columns in aggregations and evaluations under new grammar rules together with the column that is going to be renamed. This makes it possible to traverse the parse tree in any order in PTH-10 without losing information about which renaming instruction corresponds to which column. Previously the rename instruction had to be parsed directly after the corresponding column, which makes parsing unnecessarily difficult.
Created tests to assert the parse tree is correct in these cases.
The grammar should not have changed at all in this PR! Only the grammar rules change, which creates a need for changes in PTH-10 when traversing the parse tree. DPL language stays the same though.
Evaluation functions had no tests yet in timechart. New issue #93 was opened about those, as a bug was found when testing them. The test introduced in this PR makes sure that the renaming of eval functions works as intended.