equal
deleted
inserted
replaced
125 methodHome |
125 methodHome |
126 "return the method-home for block contexts" |
126 "return the method-home for block contexts" |
127 |
127 |
128 |con h| |
128 |con h| |
129 |
129 |
130 home isNil ifTrue:[^ nil]. "XXX will change soon" |
|
131 home isContext ifFalse:[^ nil]. "copying blocks have no method home" |
130 home isContext ifFalse:[^ nil]. "copying blocks have no method home" |
132 |
131 |
133 con := self. |
|
134 h := home. |
132 h := home. |
135 [h notNil] whileTrue:[ |
133 [ |
136 con := h. |
134 con := h. |
137 h := con home |
135 h := con home |
138 ]. |
136 ] doWhile:[h notNil]. |
139 ^ con |
137 ^ con |
140 ! |
138 ! |
141 |
139 |
142 selector |
140 selector |
143 "return the selector of the context - which is one of the value |
141 "return the selector of the context - which is one of the value |
167 return something useful, even in case internals of the system |
165 return something useful, even in case internals of the system |
168 got corrupted ... (i.e. avoid messageNotUnderstood here)" |
166 got corrupted ... (i.e. avoid messageNotUnderstood here)" |
169 |
167 |
170 |cls who mHome m className sel homeSel| |
168 |cls who mHome m className sel homeSel| |
171 |
169 |
172 (home isNil or:[home isContext not]) ifTrue:[ |
170 home isContext ifFalse:[ |
173 " |
171 " |
174 mhmh - an optimized blocks context |
172 mhmh - an optimized blocks context |
175 should get the block here, and get the method from |
173 should get the block here, and get the method from |
176 that one ... |
174 that one ... |
177 ... but in 2.x, there is no easy way to get to the block |
175 ... but in 2.x, there is no easy way to get to the block |
252 ! ! |
250 ! ! |
253 |
251 |
254 !BlockContext class methodsFor:'documentation'! |
252 !BlockContext class methodsFor:'documentation'! |
255 |
253 |
256 version |
254 version |
257 ^ '$Header: /cvs/stx/stx/libbasic/BlockContext.st,v 1.35 2012-07-19 09:24:00 cg Exp $' |
255 ^ '$Header: /cvs/stx/stx/libbasic/BlockContext.st,v 1.36 2013-05-07 13:23:42 stefan Exp $' |
258 ! |
256 ! |
259 |
257 |
260 version_CVS |
258 version_CVS |
261 ^ '$Header: /cvs/stx/stx/libbasic/BlockContext.st,v 1.35 2012-07-19 09:24:00 cg Exp $' |
259 ^ '$Header: /cvs/stx/stx/libbasic/BlockContext.st,v 1.36 2013-05-07 13:23:42 stefan Exp $' |
262 ! ! |
260 ! ! |
|
261 |