[ENH] Filecreation ([er] nonsense, please reject)

stéphane ducasse ducasse at iam.unibe.ch
Sun Mar 28 15:30:05 UTC 2004


thanks bert. I was sure that there was something wrong.

So now that I think about it I should have use
FileStream readOnlyFileNamed: fileName

but I got stuck in this FileDirectory

On 28 mars 04, at 17:10, Bert Freudenberg wrote:

> This changeset adds one method :
>
> 	FileDirectory class>>forLocalName: aString directoryName: 
> aDirectoryName
> 		"create a file named aString in the directory aDirectoryName"
> 	
> 		| goodFileName |
> 		goodFileName := self checkName: aDirectoryName , self  slash,   
> aString fixErrors: false.
> 		^ self on: goodFileName
>
> This is utterly nonsense because it does not create a file, as the 
> comment (or the changeset preamble) implies. It creates a 
> FileDirectory instance. We do not need that method, because the 
> canonical way to do this (using variable names like above) is:
>
> 	(FileDirectory on: aDirectoryName) directoryNamed: aString
>
>
> - Bert -
>
>




More information about the Squeak-dev mailing list