--- a/Block.st Thu Nov 03 23:31:40 2016 +0100
+++ b/Block.st Fri Nov 04 10:31:44 2016 +0100
@@ -3383,7 +3383,8 @@
a long return), evaluate the argument, aBlock.
This is used to make certain that cleanup actions (for example closing files etc.) are
executed regardless of error actions.
- Same as the more modern #ensure:"
+ Same as the more modern, ANSI standardized #ensure:,
+ which should be used instead for portability."
<exception: #unwind>
@@ -3405,10 +3406,10 @@
f := 'Makefile' asFilename readStream.
[
- l := f nextLine.
- l isNil ifTrue:[^ 'oops']
+ l := f nextLine.
+ l isNil ifTrue:[^ 'oops']
] valueNowOrOnUnwindDo:[
- f close
+ f close
]
"
@@ -3419,8 +3420,9 @@
"evaluate the receiver - when some method sent within unwinds (i.e. does
a long return), evaluate the argument, aBlock.
This is used to make certain that cleanup actions (for example closing files etc.) are
- executed regardless of error actions
- Same as the more modern #ifCurtailed:"
+ executed regardless of error actions.
+ Same as the more modern, ANSI standardized #ifCurtailed:,
+ which should be used instead for portability."
<exception: #unwind>
@@ -3436,23 +3438,23 @@
s := 'Makefile' asFilename readStream.
[
- ^ self
+ ^ self
] valueOnUnwindDo:[
- Transcript showCR:'closing the stream - even though a return occurred'.
- s close
+ Transcript showCR:'closing the stream - even though a return occurred'.
+ s close
]
"
"
[
- |s|
-
- s := 'Makefile' asFilename readStream.
- [
- Processor activeProcess terminate
- ] valueOnUnwindDo:[
- Transcript showCR:'closing the stream - even though process was terminated'.
- s close
- ]
+ |s|
+
+ s := 'Makefile' asFilename readStream.
+ [
+ Processor activeProcess terminate
+ ] valueOnUnwindDo:[
+ Transcript showCR:'closing the stream - even though process was terminated'.
+ s close
+ ]
] fork
"
! !