Compress the expression string into one line for bpls
#4158
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.
Related to PR #4145
Create a function that returns a single line string representation of a derived expression. This is mainly for
bplssince one line has a more user friendly format.ExpressionTree to String Expression:
ADD({sim1/Ux},{sim1/Uy},{sim1/Uz})The current solution is not the best. We do not create derived variables on the read side so the BP5Reader provides an internal function to get the expression string from the deserializer, create an expression on it, and call the pretty-print function on the expression (which is overly complicated). I would still merge this PR like this. We will start creating derived variables on the read side and we can replace the logic with something cleaner at that point. This PR is one step in this direction since it moves the string conversion on the Expression class.