Hi norbert
I have a question:
- would not be better to even wrap the on: into the first block of
the ensure: message?
What do you mean? Can you give an example?
In VW I was used to write something like that from memory
[ f := 'foo.bar' asFilename.
f open....
] ensure: [f close]
so the file creation was protected.
- do we have to close a file even if its creation failed?
Is there anything in the above examples that raises this question?
Usually it is the other way round. You can't close a file (that you
don't have) if the creation failed.
I was wondering about the name of the methods. Is a idiom
smthg create
aBlock value: smthg
smthg destroy
not supposed to be called during: ?
Yes but apparently in FileStream there are newfileNamed:do:....
I guess that this is a ruby idiom imported by avi
Stef
Norbert
_______________________________________________
Pharo-project mailing list
[email protected]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
_______________________________________________
Pharo-project mailing list
[email protected]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project