VM Maker: FileAttributesPlugin.oscog-eem.59.mcz

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

VM Maker: FileAttributesPlugin.oscog-eem.59.mcz

commits-2
 
Eliot Miranda uploaded a new version of FileAttributesPlugin to project VM Maker:
http://source.squeak.org/VMMaker/FileAttributesPlugin.oscog-eem.59.mcz

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

Name: FileAttributesPlugin.oscog-eem.59
Author: eem
Time: 6 September 2020, 8:24:48.563945 pm
UUID: 9ba1691a-0301-4e11-9903-c2a0aa91cee4
Ancestors: FileAttributesPlugin.oscog-eem.58

And fix yet another regression in eliding the first element (S_IFMT) by mistake.

=============== Diff against FileAttributesPlugin.oscog-eem.58 ===============

Item was changed:
  ----- Method: FileAttributesPlugin>>primitiveFileMasksAsArray (in category 'file primitives') -----
  primitiveFileMasksAsArray
  "Answer an array of well known file masks"
 
  <inline: #always>
  | masksArray masks |
  masksArray := interpreterProxy instantiateClass: interpreterProxy classArray indexableSize: 8.
  masksArray ifNil: [^interpreterProxy primitiveFailFor: PrimErrNoMemory].
 
  masks := self cCoerceSimple: (interpreterProxy firstIndexableField: masksArray) to: #'sqInt *'.
 
+ masks at: 0 put: (interpreterProxy integerObjectOf: (self cCode: [#S_IFMT] inSmalltalk: [16rF000])).
+
  self cppIf: #S_IFSOCK defined ifTrue:
  [masks at: 1 put: (interpreterProxy integerObjectOf: (self cCode: [#S_IFSOCK] inSmalltalk: [16rC000]))].
 
  self cppIf: #S_IFLNK defined ifTrue:
  [masks at: 2 put: (interpreterProxy integerObjectOf: (self cCode: [#S_IFLNK] inSmalltalk: [16rA000]))].
 
  masks at: 3 put: (interpreterProxy integerObjectOf: (self cCode: [#S_IFREG] inSmalltalk: [16r8000])).
 
  self cppIf: #S_IFBLK defined ifTrue:
  [masks at: 4 put: (interpreterProxy integerObjectOf: (self cCode: [#S_IFBLK] inSmalltalk: [16r6000]))].
 
  masks at: 5 put: (interpreterProxy integerObjectOf: (self cCode: [#S_IFDIR] inSmalltalk: [16r4000])).
 
  masks at: 6 put: (interpreterProxy integerObjectOf: (self cCode: [#S_IFCHR] inSmalltalk: [16r2000])).
 
  self cppIf: #S_IFIFO defined ifTrue:
  [masks at: 7 put: (interpreterProxy integerObjectOf: (self cCode: [#S_IFIFO] inSmalltalk: [16r1000]))].
 
  interpreterProxy methodReturnValue: masksArray!