-
Notifications
You must be signed in to change notification settings - Fork 39
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
BooleanExpressionRule fixes #1295
Conversation
…+ preserve order in variables
…ution issue (replacement of sub-word)
Codecov Report
@@ Coverage Diff @@
## master #1295 +/- ##
============================================
+ Coverage 81.97% 82.01% +0.03%
- Complexity 2527 2530 +3
============================================
Files 105 105
Lines 7169 7201 +32
Branches 2053 2058 +5
============================================
+ Hits 5877 5906 +29
Misses 346 346
- Partials 946 949 +3
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report at Codecov.
|
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.
LGTM
|
||
fun size(): Int = replacements.size | ||
|
||
fun getTokenMapper(): TokenMapper<String> = orderTokenMapper |
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 think a getter for this is redundant, because you can have a public val
with the same effect as private field with public getter
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.
Thanks for suggestion, fixed
### What's done: * removed tokenMapper function and opened the variable orderedTokenMapper
Which rule and warnings did you add?
This pull request closes #1284 and #961
BooleanExpressionRule:
A & B & C
->isBar & B & C
->isfooar & foo & C
andisAdd && isAdded()
->A & Aed
!isEmpty()
->A
isA && isB is isC
->isC && isA && isC
Actions checklist
Fixme
distributive law
, need to implement it as a rule for jbool library (will be handled in BooleanExpressionRule: refactor a logic of the distributive law as a rule for jbool library #1299)