The Trunk: Files-mt.221.mcz
| Newsgroups | gmane.comp.lang.smalltalk.squeak.general |
|---|---|
| Message-ID | <[email protected]> |
Marcel Taeumel uploaded a new version of Files to project The Trunk: http://source.squeak.org/trunk/Files-mt.221.mcz ==================== Summary ==================== Name: Files-mt.221 Author: mt Time: 29 May 2026, 3:52:04.794187 pm UUID: 57e0f5c7-bd08-e248-9eed-71a964d66e0b Ancestors: Files-mt.220 Complements Multilingual-mt.291 =============== Diff against Files-mt.220 =============== Item was added: + ----- Method: FileStream class>>newForStdio: (in category 'stdio') ----- + newForStdio: moniker + "This is a hook for subclasses to initialize themselves properly." + + ^self new! Item was changed: ----- Method: FileStream class>>standardIOStreamNamed:forWrite: (in category 'stdio') ----- standardIOStreamNamed: moniker forWrite: forWrite | index | index := #(stdin stdout stderr) identityIndexOf: moniker. ^((StdioFiles ifNil: [ StdioFiles := Array new: 3 ]) at: index) ifNil: [ StdioFiles at: index put: ( (TheStdioHandles at: index) ifNil: [ ^self error: moniker, ' is unavailable' ] ifNotNil: [ :handle | + (self stdioStreamClass newForStdio: moniker) - self stdioStreamClass newForStdio openOnHandle: handle name: moniker forWrite: forWrite ]) ] ! Item was changed: ----- Method: FileStream class>>updateStdioFiles (in category 'stdio') ----- updateStdioFiles "Make sure that all existing stdio files are instances of #stdioStreamClass." StdioFiles ifNil: [ ^self ]. Stdin := Stdout := Stderr := nil. StdioFiles := StdioFiles collect: [ :file | file ifNotNil: [ file class == self stdioStreamClass ifTrue: [ file ] ifFalse: [ + (self stdioStreamClass newForStdio: file name) - self stdioStreamClass newForStdio copyFrom: file; yourself ] ] ] ! Squeak-dev mailing list -- [email protected] To unsubscribe send an email to [email protected]