Skip to content

Commit

Permalink
Cleanup: deprecation rewrites of mehtod -> compiledMethod
Browse files Browse the repository at this point in the history
  • Loading branch information
balsa-sarenac committed Apr 26, 2024
1 parent 9a1c8bd commit 51a32bf
Showing 1 changed file with 11 additions and 4 deletions.
15 changes: 11 additions & 4 deletions src/Refactoring-Core/ReRenameClassRefactoring.class.st
Expand Up @@ -132,14 +132,21 @@ ReRenameClassRefactoring >> renameReferences [
replace: className with: newName;
replaceArgument: newName withValueFrom: [ :aNode |
self refactoringError:
newName , ' already exists within the reference scope' ];
newName
, ' already exists within the reference scope' ];
yourself.
self model allReferencesToClass: class do: [ :method |
(method modelClass hierarchyDefinesVariable: newName) ifTrue: [
self refactoringError: newName , ' is already defined in hierarchy of ' , method modelClass printString ].
(method method
self refactoringError:
newName , ' is already defined in hierarchy of '
, method modelClass printString ].
(method compiledMethod
ifNil: [ false ]
ifNotNil: [ :m | m isFromTrait]) ifFalse: [ self convertMethod: method selector for: method modelClass using: replacer ] ]
ifNotNil: [ :m | m isFromTrait ]) ifFalse: [
self
convertMethod: method selector
for: method modelClass
using: replacer ] ]
]

{ #category : 'storing' }
Expand Down

0 comments on commit 51a32bf

Please sign in to comment.