You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Create a new method category in a class (MyClass) called 'tempCategory'.
Create a method in that category, methodInTempCategory.
Execute in workspace - MyClass removeCategory: 'tempCategory'.
At this point, category tempCategory and method methodInTempCategory are removed from the class. (We can debate whether that's proper later)
However, the method isn't really gone. Two bad things happen next.
If you try to compile the same method again, you get Stack A (below).
If you try to reload your project you get Stack B (below).
----- Stack A --------
a UserDefinedError occurred (error 2318), reason:halt, Duplicate definition.
UserDefinedError (AbstractException) >> _signalWith: @5 line 25
UserDefinedError (AbstractException) >> signal @2 line 47
RwClassDefinition (Object) >> error: @6 line 7
RwClassDefinition (RwDefinition) >> addDefinition:to: @6 line 6
RwClassDefinition (RwAbstractClassDefinition) >> addInstanceMethodDefinition: @2 line 3
[] in ExecBlock2 (RwPrjBrowserTool) >> addOrUpdateMethod:inProtocol:forClassNamed:isMeta:inPackageNamed: @5 line 29
[] in ExecBlock3 (RwPrjBrowserTool) >> addOrUpdateMethod:inProtocol:forClassNamed:isMeta:inPackageNamed: @5 line 72
[] in ExecBlock1 (RwAbstractTool) >> definitionsForClassNamed:ifFound:ifAbsent: @14 line 11
RwGsImage class >> loadedClassNamed:ifFound:ifAbsent: @9 line 11
RwPrjBrowserTool (RwAbstractTool) >> definitionsForClassNamed:ifFound:ifAbsent: @3 line 4
RwPrjBrowserTool >> addOrUpdateMethod:inProtocol:forClassNamed:isMeta:inPackageNamed: @12 line 69
RwPrjBrowserTool >> addOrUpdateMethod:inProtocol:forClassNamed:isMeta: @13 line 37
RowanAnsweringService class (Behavior) >> rwCompileMethod:category: @9 line 4
[] in ExecBlock0 (RowanClassService) >> compileMethod:behavior:symbolList:inCategory: @2 line 6
ExecBlock0 (ExecBlock) >> on:do: @3 line 42
[] in ExecBlock0 (RowanClassService) >> compileMethod:behavior:symbolList:inCategory: @2 line 6
ExecBlock0 (ExecBlock) >> on:do: @3 line 42
RowanClassService >> compileMethod:behavior:symbolList:inCategory: @2 line 8
RowanClassService >> saveMethodSource:category: @12 line 7
[] in ExecBlock1 (JadeServer) >> updateFromSton: @9 line 11
Array (Collection) >> do: @5 line 10
JadeServer64bit32 (JadeServer) >> updateFromSton: @7 line 6
GsNMethod class >> _gsReturnToC @1 line 1
------Stack B ------
a UserDefinedError occurred (error 2318), reason:halt, internal error - compiled method not present in method dictionary
UserDefinedError (AbstractException) >> _signalWith: @5 line 25
UserDefinedError (AbstractException) >> signal @2 line 47
RwGsMethodDeletionSymbolDictPatch (Object) >> error: @6 line 7
[] in ExecBlock0 (RwGsMethodPatch) >> compiledMethod @2 line 10
GsMethodDictionary (AbstractDictionary) >> _reportKeyNotFound:with: @5 line 6
GsMethodDictionary >> at:ifAbsent: @30 line 28
aKey = #'test1' - one of the problem methods.
RwGsMethodDeletionSymbolDictPatch (RwGsMethodPatch) >> compiledMethod @7 line 9
RwGsMethodDeletionSymbolDictPatch >> symbolDictionary @3 line 5
RwGsMethodDeletionSymbolDictPatch (RwGsPatch) >> symbolDictionaryRegistry @2 line 3
RwGsMethodDeletionSymbolDictPatch >> deleteMethodNewClasses:andExistingClasses: @5 line 9
[] in ExecBlock1 (RwGsPatchSet_254) >> removeDeletedMethods @4 line 7
[] in ExecBlock1 (Set) >> do: @2 line 11
[] in ExecBlock2 (KeyValueDictionary) >> keysDo: @2 line 7
KeyValueDictionary >> keysAndValuesDo: @23 line 20
KeyValueDictionary >> keysDo: @2 line 6
Set >> do: @3 line 11
RwGsPatchSet_254 >> removeDeletedMethods @2 line 4
RwGsPatchSet_254 >> apply @24 line 26
RwGsImage class >> applyModification_254:visitorClass:instanceMigrator: @10 line 9
RwGsImage class >> applyModification_254:instanceMigrator: @7 line 7
RwPrjLoadTool >> _loadProjectSetDefinition_254:instanceMigrator: @15 line 14
[] in ExecBlock0 (RwPrjLoadTool) >> _doProjectSetLoad_254:instanceMigrator:originalProjectSet:processedClassNames: @2 line 4
ExecBlock0 (ExecBlock) >> on:do: @3 line 42
RwPrjLoadTool >> _doProjectSetLoad_254:instanceMigrator:originalProjectSet:processedClassNames: @2 line 6
RwPrjLoadTool >> loadProjectNamed:instanceMigrator: @7 line 9
RwPrjLoadTool >> loadProjectNamed: @4 line 5
[] in ExecBlock0 (RowanProjectService) >> reloadProject @4 line 3
ExecBlock0 (ExecBlock) >> on:do: @3 line 42
RowanProjectService >> reloadProject @2 line 4
[] in ExecBlock1 (JadeServer) >> updateFromSton: @9 line 11
Array (Collection) >> do: @5 line 10
JadeServer64bit32 (JadeServer) >> updateFromSton: @7 line 6
GsNMethod class >> _gsReturnToC @1 line 1
The text was updated successfully, but these errors were encountered:
To reproduce:
'tempCategory'
.methodInTempCategory
.MyClass removeCategory: 'tempCategory'.
At this point, category
tempCategory
and methodmethodInTempCategory
are removed from the class. (We can debate whether that's proper later)However, the method isn't really gone. Two bad things happen next.
----- Stack A --------
a UserDefinedError occurred (error 2318), reason:halt, Duplicate definition.
UserDefinedError (AbstractException) >> _signalWith: @5 line 25
UserDefinedError (AbstractException) >> signal @2 line 47
RwClassDefinition (Object) >> error: @6 line 7
RwClassDefinition (RwDefinition) >> addDefinition:to: @6 line 6
RwClassDefinition (RwAbstractClassDefinition) >> addInstanceMethodDefinition: @2 line 3
[] in ExecBlock2 (RwPrjBrowserTool) >> addOrUpdateMethod:inProtocol:forClassNamed:isMeta:inPackageNamed: @5 line 29
[] in ExecBlock3 (RwPrjBrowserTool) >> addOrUpdateMethod:inProtocol:forClassNamed:isMeta:inPackageNamed: @5 line 72
[] in ExecBlock1 (RwAbstractTool) >> definitionsForClassNamed:ifFound:ifAbsent: @14 line 11
RwGsImage class >> loadedClassNamed:ifFound:ifAbsent: @9 line 11
RwPrjBrowserTool (RwAbstractTool) >> definitionsForClassNamed:ifFound:ifAbsent: @3 line 4
RwPrjBrowserTool >> addOrUpdateMethod:inProtocol:forClassNamed:isMeta:inPackageNamed: @12 line 69
RwPrjBrowserTool >> addOrUpdateMethod:inProtocol:forClassNamed:isMeta: @13 line 37
RowanAnsweringService class (Behavior) >> rwCompileMethod:category: @9 line 4
[] in ExecBlock0 (RowanClassService) >> compileMethod:behavior:symbolList:inCategory: @2 line 6
ExecBlock0 (ExecBlock) >> on:do: @3 line 42
[] in ExecBlock0 (RowanClassService) >> compileMethod:behavior:symbolList:inCategory: @2 line 6
ExecBlock0 (ExecBlock) >> on:do: @3 line 42
RowanClassService >> compileMethod:behavior:symbolList:inCategory: @2 line 8
RowanClassService >> saveMethodSource:category: @12 line 7
[] in ExecBlock1 (JadeServer) >> updateFromSton: @9 line 11
Array (Collection) >> do: @5 line 10
JadeServer64bit32 (JadeServer) >> updateFromSton: @7 line 6
GsNMethod class >> _gsReturnToC @1 line 1
------Stack B ------
a UserDefinedError occurred (error 2318), reason:halt, internal error - compiled method not present in method dictionary
UserDefinedError (AbstractException) >> _signalWith: @5 line 25
UserDefinedError (AbstractException) >> signal @2 line 47
RwGsMethodDeletionSymbolDictPatch (Object) >> error: @6 line 7
[] in ExecBlock0 (RwGsMethodPatch) >> compiledMethod @2 line 10
GsMethodDictionary (AbstractDictionary) >> _reportKeyNotFound:with: @5 line 6
GsMethodDictionary >> at:ifAbsent: @30 line 28
aKey = #'test1' - one of the problem methods.
RwGsMethodDeletionSymbolDictPatch (RwGsMethodPatch) >> compiledMethod @7 line 9
RwGsMethodDeletionSymbolDictPatch >> symbolDictionary @3 line 5
RwGsMethodDeletionSymbolDictPatch (RwGsPatch) >> symbolDictionaryRegistry @2 line 3
RwGsMethodDeletionSymbolDictPatch >> deleteMethodNewClasses:andExistingClasses: @5 line 9
[] in ExecBlock1 (RwGsPatchSet_254) >> removeDeletedMethods @4 line 7
[] in ExecBlock1 (Set) >> do: @2 line 11
[] in ExecBlock2 (KeyValueDictionary) >> keysDo: @2 line 7
KeyValueDictionary >> keysAndValuesDo: @23 line 20
KeyValueDictionary >> keysDo: @2 line 6
Set >> do: @3 line 11
RwGsPatchSet_254 >> removeDeletedMethods @2 line 4
RwGsPatchSet_254 >> apply @24 line 26
RwGsImage class >> applyModification_254:visitorClass:instanceMigrator: @10 line 9
RwGsImage class >> applyModification_254:instanceMigrator: @7 line 7
RwPrjLoadTool >> _loadProjectSetDefinition_254:instanceMigrator: @15 line 14
[] in ExecBlock0 (RwPrjLoadTool) >> _doProjectSetLoad_254:instanceMigrator:originalProjectSet:processedClassNames: @2 line 4
ExecBlock0 (ExecBlock) >> on:do: @3 line 42
RwPrjLoadTool >> _doProjectSetLoad_254:instanceMigrator:originalProjectSet:processedClassNames: @2 line 6
RwPrjLoadTool >> loadProjectNamed:instanceMigrator: @7 line 9
RwPrjLoadTool >> loadProjectNamed: @4 line 5
[] in ExecBlock0 (RowanProjectService) >> reloadProject @4 line 3
ExecBlock0 (ExecBlock) >> on:do: @3 line 42
RowanProjectService >> reloadProject @2 line 4
[] in ExecBlock1 (JadeServer) >> updateFromSton: @9 line 11
Array (Collection) >> do: @5 line 10
JadeServer64bit32 (JadeServer) >> updateFromSton: @7 line 6
GsNMethod class >> _gsReturnToC @1 line 1
The text was updated successfully, but these errors were encountered: