equal
deleted
inserted
replaced
151 exit |
151 exit |
152 "exit the monitor" |
152 "exit the monitor" |
153 |
153 |
154 |thisProcess| |
154 |thisProcess| |
155 |
155 |
|
156 count == 0 ifTrue:[ |
|
157 'MONITOR: already left' errorPrintCR. |
|
158 ^ self |
|
159 ]. |
|
160 |
156 thisProcess := Processor activeProcess. |
161 thisProcess := Processor activeProcess. |
157 |
162 |
158 " |
163 " |
159 this works only since interrupts are only serviced at |
164 this works only since interrupts are only serviced at |
160 message send and method-return time .... |
165 message send and method-return time .... |
169 count ~~ 0 ifTrue:[ ^ self]. |
174 count ~~ 0 ifTrue:[ ^ self]. |
170 |
175 |
171 owningProcess := nil. |
176 owningProcess := nil. |
172 sema signal. |
177 sema signal. |
173 |
178 |
174 "Modified: 3.5.1996 / 17:25:57 / cg" |
179 "Modified: 6.7.1996 / 22:30:47 / cg" |
175 ! ! |
180 ! ! |
176 |
181 |
177 !Monitor methodsFor:'initialization'! |
182 !Monitor methodsFor:'initialization'! |
178 |
183 |
179 initialize |
184 initialize |
206 ! ! |
211 ! ! |
207 |
212 |
208 !Monitor class methodsFor:'documentation'! |
213 !Monitor class methodsFor:'documentation'! |
209 |
214 |
210 version |
215 version |
211 ^ '$Header: /cvs/stx/stx/libbasic2/Monitor.st,v 1.4 1996-06-27 15:54:25 cg Exp $' |
216 ^ '$Header: /cvs/stx/stx/libbasic2/Monitor.st,v 1.5 1996-07-06 21:54:52 cg Exp $' |
212 ! ! |
217 ! ! |