[squeak-dev] The Trunk: System-eem.1245.mcz

commits at source.squeak.org commits at source.squeak.org
Thu Nov 4 19:39:47 UTC 2021

Eliot Miranda uploaded a new version of System to project The Trunk:

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

Name: System-eem.1245
Author: eem
Time: 4 November 2021, 12:39:44.080578 pm
UUID: c5406b85-50fb-4666-baf7-d995bdb2da41
Ancestors: System-eem.1244

Project: Abstract nilParentError, shared between a couple of accessors (new topMorphicProject).  Add an instance side topProject to compliment topMorphicProject.

=============== Diff against System-eem.1244 ===============

Item was changed:
  ----- Method: Project>>isTopProject (in category 'sub-projects & hierarchy') -----
+ 	"Answer if this is the top project (its own parent).
- 	"Return true only if this is the top project (its own parent).
  	Also include the test here for malformed project hierarchy."
  	parentProject == self ifTrue: [^ true].
+ 	parentProject == nil ifTrue: [self nilParentError].
- 	parentProject == nil ifTrue: [self error: 'No project should have a nil parent'].
  	^ false!

Item was added:
+ ----- Method: Project>>nilParentError (in category 'accessing') -----
+ nilParentError
+ 	self error: 'No project should have a nil parent'!

Item was added:
+ ----- Method: Project>>topProject (in category 'accessing') -----
+ topProject
+ 	"Answer the topProject for this project's hierarchy"
+ 	parentProject == self ifTrue: [^self].
+ 	parentProject == nil ifTrue: [self nilParentError].
+ 	^parentProject topProject!

More information about the Squeak-dev mailing list