equal
deleted
inserted
replaced
123 bindingOf: varName |
123 bindingOf: varName |
124 "Answer the binding of some variable resolved in the scope of the receiver" |
124 "Answer the binding of some variable resolved in the scope of the receiver" |
125 |
125 |
126 | aSymbol binding | |
126 | aSymbol binding | |
127 |
127 |
128 self shouldImplement. "not yet finished" |
128 "/ self shouldImplement. "not yet finished" |
129 aSymbol := varName asSymbol. |
129 aSymbol := varName asSymbol. |
130 |
130 |
131 "First look in classVar dictionary." |
131 "First look in classVar dictionary." |
132 binding := self classPool bindingOf: aSymbol. |
132 binding := self classPool bindingOf: aSymbol. |
133 binding notNil ifTrue:[^binding]. |
133 binding notNil ifTrue:[^binding]. |
139 ]. |
139 ]. |
140 |
140 |
141 "subclassing and environment are not preserved" |
141 "subclassing and environment are not preserved" |
142 ^nil |
142 ^nil |
143 |
143 |
144 "Modified: / 08-08-2010 / 14:46:09 / cg" |
144 "Modified: / 12-09-2011 / 09:40:36 / cg" |
145 ! |
145 ! |
146 |
146 |
147 bindingsDo: aBlock |
147 bindingsDo: aBlock |
148 self halt:'unfinished implementation'. |
148 self classVarNames do:[:eachKey | |
149 ^ self classPool bindingsDo: aBlock |
149 aBlock value:(eachKey -> (self classVarAt:eachKey)) |
|
150 ]. |
|
151 |
|
152 "Modified: / 12-09-2011 / 09:42:00 / cg" |
150 ! |
153 ! |
151 |
154 |
152 classBindingOf: varName |
155 classBindingOf: varName |
153 "For initialization messages grant the regular scope" |
156 "For initialization messages grant the regular scope" |
154 |
157 |
204 ! ! |
207 ! ! |
205 |
208 |
206 !SharedPool class methodsFor:'documentation'! |
209 !SharedPool class methodsFor:'documentation'! |
207 |
210 |
208 version |
211 version |
209 ^ '$Header: /cvs/stx/stx/libbasic/SharedPool.st,v 1.16 2011-09-08 12:38:59 cg Exp $' |
212 ^ '$Header: /cvs/stx/stx/libbasic/SharedPool.st,v 1.17 2011-09-12 08:21:51 cg Exp $' |
210 ! |
213 ! |
211 |
214 |
212 version_CVS |
215 version_CVS |
213 ^ '$Header: /cvs/stx/stx/libbasic/SharedPool.st,v 1.16 2011-09-08 12:38:59 cg Exp $' |
216 ^ '$Header: /cvs/stx/stx/libbasic/SharedPool.st,v 1.17 2011-09-12 08:21:51 cg Exp $' |
214 ! ! |
217 ! ! |