[squeak-dev] The Trunk: Files-nice.50.mcz

commits at source.squeak.org commits at source.squeak.org
Mon Dec 7 21:05:16 UTC 2009


Nicolas Cellier uploaded a new version of Files to project The Trunk:
http://source.squeak.org/trunk/Files-nice.50.mcz

==================== Summary ====================

Name: Files-nice.50
Author: nice
Time: 7 December 2009, 10:04:56 am
UUID: 2ca8c18f-0384-4eec-bd69-46ad229fb758
Ancestors: Files-nice.49

Throw away another #getSystemAttribute:
Please don't spread cryptic code in the system! Use clear messages instead.

=============== Diff against Files-nice.49 ===============

Item was changed:
  ----- Method: CrLfFileStream class>>guessDefaultLineEndConvention (in category 'class initialization') -----
  guessDefaultLineEndConvention
  	"Lets try to guess the line end convention from what we know about the
  	path name delimiter from FileDirectory."
  	FileDirectory pathNameDelimiter = $:
  		ifTrue: [^ self defaultToCR].
  	FileDirectory pathNameDelimiter = $/
+ 		ifTrue: [((SmalltalkImage current osVersion) beginsWith: 'darwin')
- 		ifTrue: [((SmalltalkImage current getSystemAttribute: 1002) beginsWith: 'darwin')
  				ifTrue: [^ self defaultToCR]
  				ifFalse: [^ self defaultToLF]].
  	FileDirectory pathNameDelimiter = $\
  		ifTrue: [^ self defaultToCRLF].
  	"in case we don't know"
  	^ self defaultToCR!




More information about the Squeak-dev mailing list