--- a/ByteCodeCompiler.st Mon Dec 04 22:24:00 2000 +0100
+++ b/ByteCodeCompiler.st Mon Dec 04 22:35:32 2000 +0100
@@ -904,10 +904,16 @@
newMethod source:aString string.
].
newMethod setCategory:cat.
- aClass owningClass isNil ifTrue:[
- pkg := Class packageQuerySignal query.
+
+ (install not
+ and:[(oldMethod := aClass compiledMethodAt:sel) notNil]) ifTrue:[
+ pkg := oldMethod package
] ifFalse:[
- pkg := aClass owningClass package
+ aClass owningClass isNil ifTrue:[
+ pkg := Class packageQuerySignal query.
+ ] ifFalse:[
+ pkg := aClass owningClass package
+ ].
].
newMethod setPackage:pkg.
@@ -3574,6 +3580,7 @@
oldMethod isNil ifTrue:[
aClass removeSelector:selector
] ifFalse:[
+ newMethod setPackage:oldMethod package.
aClass addSelector:selector withMethod:oldMethod.
oldMethod setPackage:pkg.
]
@@ -3728,6 +3735,6 @@
!ByteCodeCompiler class methodsFor:'documentation'!
version
- ^ '$Header: /cvs/stx/stx/libcomp/ByteCodeCompiler.st,v 1.181 2000-12-04 21:24:00 cg Exp $'
+ ^ '$Header: /cvs/stx/stx/libcomp/ByteCodeCompiler.st,v 1.182 2000-12-04 21:35:32 cg Exp $'
! !
ByteCodeCompiler initialize!