The Trunk: Files-tfel.165.mcz

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

The Trunk: Files-tfel.165.mcz

commits-2
Tim Felgentreff uploaded a new version of Files to project The Trunk:
http://source.squeak.org/trunk/Files-tfel.165.mcz

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

Name: Files-tfel.165
Author: tfel
Time: 30 August 2016, 10:42:22.521946 am
UUID: 45b18cd1-022d-824f-8b83-077e3908cb22
Ancestors: Files-tfel.162, Files-dtl.164

merge translation and read-only check from Squeakland Etoys

=============== Diff against Files-dtl.164 ===============

Item was changed:
  ----- Method: FileStream class>>serviceFileIn (in category 'file reader services') -----
  serviceFileIn
  "Answer a service for filing in an entire file"
 
  ^ SimpleServiceEntry
  provider: self
+ label: 'fileIn entire file' translatedNoop
- label: 'fileIn entire file'
  selector: #fileIn:
+ description: 'file in the entire contents of the file, which is expected to contain Smalltalk code in fileout ("chunk") format' translatedNoop
+ buttonLabel: 'filein' translatedNoop!
- description: 'file in the entire contents of the file, which is expected to contain Smalltalk code in fileout ("chunk") format'
- buttonLabel: 'filein'!

Item was changed:
  ----- Method: FileStream class>>serviceRemoveLineFeeds (in category 'file reader services') -----
  serviceRemoveLineFeeds
  "Answer a service for removing linefeeds from a file"
 
  ^ FileModifyingSimpleServiceEntry
  provider: self
+ label: 'remove line feeds' translatedNoop
- label: 'remove line feeds'
  selector: #removeLineFeeds:
+ description: 'remove line feeds in file' translatedNoop
+ buttonLabel: 'remove lfs' translatedNoop!
- description: 'remove line feeds in file'
- buttonLabel: 'remove lfs'!

Item was changed:
  ----- Method: RemoteString>>string:onFileNumber: (in category 'private') -----
  string: aString onFileNumber: fileNumber
  "Store this as my string if source files exist."
+ (SourceFiles at: fileNumber) ifNotNil: [:theFile |
+ theFile isReadOnly ifTrue: [^ nil].
- | theFile |
- (SourceFiles at: fileNumber) == nil ifFalse:
- [theFile := SourceFiles at: fileNumber.
  theFile setToEnd; cr.
+ self string: aString onFileNumber: fileNumber toFile: theFile].!
- self string: aString onFileNumber: fileNumber toFile: theFile]!


Reply | Threaded
Open this post in threaded view
|

Re: The Trunk: Files-tfel.165.mcz

Levente Uzonyi
On Tue, 30 Aug 2016, [hidden email] wrote:

> Tim Felgentreff uploaded a new version of Files to project The Trunk:
> http://source.squeak.org/trunk/Files-tfel.165.mcz
>
> ==================== Summary ====================
>
> Name: Files-tfel.165
> Author: tfel
> Time: 30 August 2016, 10:42:22.521946 am
> UUID: 45b18cd1-022d-824f-8b83-077e3908cb22
> Ancestors: Files-tfel.162, Files-dtl.164
>
> merge translation and read-only check from Squeakland Etoys
>
> =============== Diff against Files-dtl.164 ===============
>

snip

> Item was changed:
>  ----- Method: RemoteString>>string:onFileNumber: (in category 'private') -----
>  string: aString onFileNumber: fileNumber
>   "Store this as my string if source files exist."
> + (SourceFiles at: fileNumber) ifNotNil: [:theFile |
> + theFile isReadOnly ifTrue: [^ nil].

Since we use read-only files for reading the sources, this change will
break stuff. What's the point of this change anyway?

Levente

> - | theFile |
> - (SourceFiles at: fileNumber) == nil ifFalse:
> - [theFile := SourceFiles at: fileNumber.
>   theFile setToEnd; cr.
> + self string: aString onFileNumber: fileNumber toFile: theFile].!
> - self string: aString onFileNumber: fileNumber toFile: theFile]!
>
>
>