#BUGFIX by stefan
class: InstrumentationContext
changed: #forProcess:
do not keep references to dead processes (allow them to be garbage collected)
--- a/InstrumentationContext.st Thu Jun 30 20:12:04 2016 +0200
+++ b/InstrumentationContext.st Tue Jul 05 18:13:42 2016 +0200
@@ -11,6 +11,8 @@
"
"{ Package: 'stx:libcomp' }"
+"{ NameSpace: Smalltalk }"
+
Object variableSubclass:#InstrumentationContext
instanceVariableNames:'inInstrumentedCode enabled coverageOnly'
classVariableNames:'LastProcess LastInstrumentationContext
@@ -83,6 +85,14 @@
|p context|
+ aProcess isDead ifTrue:[
+ "do not keep dead processes from being garbage collected"
+ aProcess == LastProcess ifTrue:[
+ LastProcess := LastInstrumentationContext := nil.
+ ].
+ ^ GlobalInstrumentationContext.
+ ].
+
aProcess == LastProcess ifTrue:[
^ LastInstrumentationContext ? GlobalInstrumentationContext
].
@@ -326,10 +336,10 @@
!InstrumentationContext class methodsFor:'documentation'!
version
- ^ '$Header: /cvs/stx/stx/libcomp/InstrumentationContext.st,v 1.15 2014-12-23 12:42:46 cg Exp $'
+ ^ '$Header$'
!
version_CVS
- ^ '$Header: /cvs/stx/stx/libcomp/InstrumentationContext.st,v 1.15 2014-12-23 12:42:46 cg Exp $'
+ ^ '$Header$'
! !