Merged
Conversation
properties and macros in (typically 3rd party) include files - enable the new behaviour by passing --inorder cmdline option - to improve code readibility and reusability, introduced functions process_include(node), grab_macro(elt, macros), grab_property(elt, symbols) containing 1:1 corresponding handling from process_includes, grab_macros, and grab_properties - added corresponding test case test_inorder_processing()
- replaced handle_expr with python-internal eval() call - care has been taken to resolve variables recursively on demand (in Table.__getitem__) - allows for evaluation of standard math functions - other desired functions could be added in eval_self_contained - Values in Table symbols are not stored as strings but as typed values. If text is required, a conversion with str() is performed. This is need to ensure proper evaluation of expressions. Otherwise 3*"1" would evaluate to "111". - using __future__.division we can handle int division evaluating to float as before
- for equality expressions in <xacro:if> - math function usage
- literal evaluation should only consider literals, but no expressions use ast.literal_eval() - removed eval() from xacro:if evaluation back to string comparison to handle (lowercase) true and false
codebot
added a commit
that referenced
this pull request
Mar 13, 2015
python eval, new test cases, ordering improvements
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Retargeted #50 to jade-devel branch.