Marcel Taeumel uploaded a new version of System to project The Trunk:
http://source.squeak.org/trunk/System-mt.1215.mcz
==================== Summary ====================
Name: System-mt.1215
Author: mt
Time: 17 February 2021, 3:42:18.125168 pm
UUID: 5c7faa4b-79dd-c14c-a76e-2d1f9baec59d
Ancestors: System-cmm.1214
Fixes a regression caused by not-too-distant change in ReleaseBuilder to reset all pragma preferences in CI.
Thanks to Jaromir for pointing this out!
=============== Diff against System-cmm.1214 ===============
Item was changed:
----- Method: MessageTally class>>showProcesses (in category 'defaults') -----
showProcesses
"Indicates whether to show each process separately or cumulatively.
For example, compare the spy results of the following with both values:
[1000 timesRepeat: [3.14159 printString. Processor yield]] fork.
[1000 timesRepeat: [30 factorial. Processor yield]] fork.
[1000 timesRepeat: [30 factorial. Processor yield]] fork.
MessageTally spyAllOn: [ (Delay forMilliseconds: 100) wait]
"
<preference: 'Show Tally Processes'
category: 'debug'
description: 'When true, show individual processes in MessageTally'
type: #Boolean>
+ ^ShowProcesses ifNil: [true]!
- ^ShowProcesses!
Marcel Taeumel uploaded a new version of Morphic to project The Trunk:
http://source.squeak.org/trunk/Morphic-mt.1722.mcz
==================== Summary ====================
Name: Morphic-mt.1722
Author: mt
Time: 16 February 2021, 10:10:46.500005 am
UUID: 5d63cf8f-7e43-4f77-8ab3-fb3239223af2
Ancestors: Morphic-eem.1721
Minor tweaks to icon cache in LazyList:
- Flag missing icons with #none to avoid repeated model access
- Support no-icon separator items, thus avoiding minor visual glitch (e.g., in Git Browser's list of branches)
Note that it felt right to format #iconExtent this way to emphasize the ordered variations of lazy init. =)
=============== Diff against Morphic-eem.1721 ===============
Item was changed:
----- Method: LazyListMorph>>icon: (in category 'list access - cached') -----
icon: row
+ "Answer a cached form from the model at a specific row. By flagging nil-icons with #none, only try to fetch an icon once from the model until next #listChanged. Also do inst-var access on listIcons here to initialize it as late as possible."
- "Do inst-var access on listIcons here to initialize it as late as possible."
self listSource canHaveIcons ifFalse: [^ nil].
listIcons ifNil: [listIcons := Array new: self getListSize].
+
+ ^ (listIcons at: row)
+ ifNotNil: [:iconOrNone | iconOrNone == #none ifFalse: [iconOrNone]]
+ ifNil: [
+ | icon |
+ icon := (self getListIcon: row) ifNotNil: [:form | form scaleIconToDisplay].
+ "Update cache for uniform icon extent."
+ iconExtent ifNil: [iconExtent := icon ifNotNil: [icon extent]].
+ listIcons at: row put: (icon ifNil: [#none]).
+ icon]!
-
- ^ (listIcons at: row) ifNil: [
- | icon |
- icon := (self getListIcon: row) ifNotNil: [:form | form scaleIconToDisplay].
- "Update cache for uniform icon extent."
- iconExtent ifNil: [iconExtent := icon ifNotNil: [icon extent]].
- listIcons at: row put: icon.
- icon]!
Item was changed:
----- Method: LazyListMorph>>iconExtent (in category 'layout') -----
iconExtent
+ "Answers the uniform icon extent for this lazy list based on sample icons from the list source."
+ | listSize |
+ iconExtent ifNil: [
+
+ self listSource canHaveIcons
+ ifFalse: [^ iconExtent := 0@0].
+
+ (listSize := self getListSize) = 0
+ ifTrue: [^ iconExtent := ((14@14) * RealEstateAgent scaleFactor) truncated].
+
+ (self icon: (2 min: listSize)) "mt: Use second item bc. first one might be visual separator w/o icon."
+ ifNil: [^ iconExtent := 0@0]
+ ifNotNil: [:form | ^ iconExtent := form extent]].
+
+ ^ iconExtent!
- ^ iconExtent ifNil: [
- self getListSize = 0
- ifTrue: [((14@14) * RealEstateAgent scaleFactor) truncated]
- ifFalse: [(self icon: 1) ifNil: [0@0] ifNotNil: [:form | form extent]]]!
David T. Lewis uploaded a new version of CollectionsTests to project The Trunk:
http://source.squeak.org/trunk/CollectionsTests-dtl.350.mcz
==================== Summary ====================
Name: CollectionsTests-dtl.350
Author: dtl
Time: 13 February 2021, 4:37:17.676276 pm
UUID: c4060470-23b9-4b11-a961-41baeb166af8
Ancestors: CollectionsTests-ul.348
Do not include new test from CollectionsTests-jar.349 because it documents existing behavior that may not necessarily be the expected behavior. Discussion at http://lists.squeakfoundation.org/pipermail/squeak-dev/2021-February/213918…
=============== Diff against CollectionsTests-ul.348 ===============
Nicolas Cellier uploaded a new version of Kernel to project The Trunk:
http://source.squeak.org/trunk/Kernel-nice.1368.mcz
==================== Summary ====================
Name: Kernel-nice.1368
Author: nice
Time: 11 February 2021, 9:30:07.084854 am
UUID: b086833d-ece4-4372-b252-87d2caa59193
Ancestors: Kernel-eem.1367
Rescue setting of Processor highestPriority: anInteger
There was a double problem:
1) if reducing the priority, then anyProcessesAbove: did behave as noProcessAbove: because (select:) isEmpty <=> noneSatisfy:
It should have been (reject:) empty or (select:) notEmpty, but we have anySatisfy: for expressing this intention
2) if increasing the priority, then the loop did overwrite the last LinkedList in the quiescentProcessLists
Those LinkedList are mostly empty in my own image, and we never change the highestPriority, so the bug was probably benign...
=============== Diff against Kernel-eem.1367 ===============
Item was changed:
----- Method: ProcessorScheduler>>anyProcessesAbove: (in category 'private') -----
anyProcessesAbove: highestPriority
+ "Do any (sub) instances of Process exist with higher priorities?"
- "Do any instances of Process exist with higher priorities?"
+ ^(Process allSubInstances anySatisfy: [:aProcess |
+ aProcess priority > highestPriority])!
- ^(Process allSubInstances select: [:aProcess |
- aProcess priority > highestPriority]) isEmpty
- "If anyone ever makes a subclass of Process, be sure to use allSubInstances."!
Item was changed:
----- Method: ProcessorScheduler>>highestPriority: (in category 'accessing') -----
highestPriority: newHighestPriority
"Change the number of priority levels currently available for use."
| newProcessLists |
(quiescentProcessLists size > newHighestPriority
and: [self anyProcessesAbove: newHighestPriority])
ifTrue: [self error: 'There are processes with priority higher than '
,newHighestPriority printString].
newProcessLists := Array new: newHighestPriority.
+ 1 to: (quiescentProcessLists size min: newProcessLists size) do:
- 1 to: ((quiescentProcessLists size) min: (newProcessLists size)) do:
[:priority | newProcessLists at: priority put: (quiescentProcessLists at: priority)].
+ quiescentProcessLists size + 1 to: newProcessLists size do:
- (quiescentProcessLists size max: 1) to: newProcessLists size do:
[:priority | newProcessLists at: priority put: LinkedList new].
quiescentProcessLists := newProcessLists!
Chris Muller uploaded a new version of System to project The Trunk:
http://source.squeak.org/trunk/System-cmm.1214.mcz
==================== Summary ====================
Name: System-cmm.1214
Author: cmm
Time: 5 February 2021, 10:09:05.179247 pm
UUID: d6f968d9-a638-42ef-89ef-d37af0f31ffd
Ancestors: System-mt.1213
Patch the patcher. Smalltalk run: permits the patching of a production system without having to resort to running a custom image, but when the patch.st file has read-only status in the OS, FileStream class>>#fileNamed:do: can't open it, because it tries to open for read/write. But rather htan signal an error, it silently does nothing (wow), leaving the system unpatched.
Patch files can and should be read-only anyway, so use DirectoryEntryFile>>#readStreamDo:.
=============== Diff against System-mt.1213 ===============
Item was changed:
----- Method: SmalltalkImage>>patchSystem (in category 'command line') -----
patchSystem
'patch.st' asDirectoryEntry ifNotNil:
[ : patchEntry | patchEntry modificationTime > Smalltalk imageName asDirectoryEntry modificationTime
ifTrue:
[ Notification signal: 'Patching system...'.
+ patchEntry readStreamDo: [ : stream | stream fileIn ] ]
- FileStream
- fileNamed: 'patch.st'
- do:
- [ : stream | stream fileIn ] ]
ifFalse: [ self error: 'patch.st file is older than the image file. Aborting.' ] ]!