-
Notifications
You must be signed in to change notification settings - Fork 43
Remove old TermLike simplifier #2767
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
…ve-old-term-simplifier
|
…re into remove-old-term-simplifier
This reverts commit 17bd41e.
…mplification' into remove-old-term-simplifier
…/kore into implement-predicate-generator
…re into remove-old-term-simplifier
…re into remove-old-term-simplifier
|
|
|
I tested the performance locally and |
|
|
| simplifiedTerm <- simplifyConditionalTerm sideCondition rewritingTerm | ||
| simplifyCondition sideCondition $ | ||
| Pattern.andCondition simplifiedTerm rewritingCondition | ||
| reevaluateFunctions = simplifyPattern |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do you think it's useful to keep reevaluateFunctions since it's just another name for simplifyPattern?
|
|
| SideCondition variable -> | ||
| Bool | ||
| areIncludedIn predicates sideCondition = | ||
| all (flip isIncludedIn sideCondition) predicates |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If isIncludedIn is only used here, does it make sense to flip the arguments here instead of simply flipping the arguments in the definition? Of course the name would need to be modified.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wanted it to be similar to the elem function, so that the order of the arguments is intuitive.
|
|
Fixes #2770
Needs #2766, #2758, #2796 and #2805
The
TermLikesimplifier does not simplify predicates anymore, removing the complicated loop inside theTermLikesimplifier. The interface to the simplifier is nowsimplifyPattern, which takes care of simplifying the term and condition together. This has resulted in multiple unit tests needing changes, in particular those which had too general test data (TermLikes which containedPredicates).Review checklist
The author performs the actions on the checklist. The reviewer evaluates the work and checks the boxes as they are completed.