Skip to content

Commit

Permalink
Renamed isForMethod to isRuleForMethod
Browse files Browse the repository at this point in the history
  • Loading branch information
jordanmontt committed Dec 3, 2022
1 parent 43d9b6c commit ffdeac1
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion src/RewriteRuleTools/ApplyRuleOnAllClassesCommand.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ ApplyRuleOnAllClassesCommand >> execute [
ifFalse: [ ^ self ].
ruleHolder := RTAbstractApplier
createRuleHolder: self context lhs -> self context rhs
isforMethod: self context isForMethod.
isforMethod: self context isRuleForMethod.

changes := RTAbstractApplier defaultEngineApplier
calculateAllChangesForRules: ruleHolder asOrderedCollection.
Expand Down
2 changes: 1 addition & 1 deletion src/RewriteRulesRewriter/RTRBApplier.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ RTRBApplier class >> rewriter: ruleHolderCollection [
| rewriter |
rewriter := RBParseTreeRewriter new.
ruleHolderCollection do: [ :ruleHolder |
ruleHolder isForMethod
ruleHolder isRuleForMethod
ifTrue: [ rewriter replaceMethod: ruleHolder lhs with: ruleHolder rhs ]
ifFalse: [ rewriter replace: ruleHolder lhs with: ruleHolder rhs ] ].
^ rewriter
Expand Down
2 changes: 1 addition & 1 deletion src/RewriteRulesRewriter/RTRenrakuApplier.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ Take a look on ReCriticEngine for some automation ideas. Also take a look at Com
critiques := OrderedCollection new.
rewriteNode := ReNodeRewriteRule new.
ruleHolderCollection do: [ :aRuleHolder |
aRuleHolder isForMethod
aRuleHolder isRuleForMethod
ifTrue: [ rewriteNode addMatchingMethod: aRuleHolder lhs rewriteTo: aRuleHolder rhs ]
ifFalse: [ rewriteNode addMatchingExpression: aRuleHolder lhs rewriteTo: aRuleHolder rhs ] ].
methodsAsSet do: [ :method |
Expand Down
8 changes: 4 additions & 4 deletions src/RewriteRulesRewriter/RTRuleHolder.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ RTRuleHolder class >> lhs: lhs rhs: rhs isForMethod: isForMethod [
^ self new
lhs: lhs;
rhs: rhs;
isForMethod: isForMethod;
isRuleForMethod: isForMethod;
yourself
]

Expand All @@ -62,7 +62,7 @@ RTRuleHolder class >> lhs: lhs rhs: rhs isForMethod: isForMethod inputCode: inpu
^ self new
lhs: lhs;
rhs: rhs;
isForMethod: isForMethod;
isRuleForMethod: isForMethod;
inputCode: inputCode;
outputCode: outputCode;
yourself
Expand Down Expand Up @@ -103,13 +103,13 @@ RTRuleHolder >> isDemoRule: anObject [
]

{ #category : #accessing }
RTRuleHolder >> isForMethod [
RTRuleHolder >> isRuleForMethod [

^ isForMethod
]

{ #category : #accessing }
RTRuleHolder >> isForMethod: anObject [
RTRuleHolder >> isRuleForMethod: anObject [

isForMethod := anObject
]
Expand Down

0 comments on commit ffdeac1

Please sign in to comment.