[squeak-dev] The Trunk: System-ul.416.mcz

commits at source.squeak.org commits at source.squeak.org
Sat Jan 29 00:53:44 UTC 2011


Levente Uzonyi uploaded a new version of System to project The Trunk:
http://source.squeak.org/trunk/System-ul.416.mcz

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

Name: System-ul.416
Author: ul
Time: 29 January 2011, 1:45:34.868 am
UUID: 4e4b642f-4878-024d-987b-a067da4382cb
Ancestors: System-cmm.415, System-fbs.410

- merged

=============== Diff against System-cmm.415 ===============

Item was changed:
  ----- Method: SystemDictionary>>classOrTraitNamed: (in category 'classes and traits') -----
  classOrTraitNamed: aString 
  	"aString is either a class or trait name or a class or trait name followed by ' class' or 'classTrait' respectively.
  	Answer the class or metaclass it names."
  
+ 	| meta baseName |
- 	| meta baseName baseClass |
  	(aString endsWith: ' class')
  		ifTrue: [meta := true.
  				baseName := aString copyFrom: 1 to: aString size - 6]
  		ifFalse: [
  			(aString endsWith: ' classTrait')
  				ifTrue: [
  					meta := true.
  					baseName := aString copyFrom: 1 to: aString size - 11]
  				ifFalse: [
  					meta := false.
  					baseName := aString]].
+ 
+ 	^self at: baseName asSymbol ifPresent:
+ 		[ :global |
+  		global isBehavior ifTrue:
+ 			[ meta
+ 				ifFalse: [ global ]
+ 				ifTrue: [ global classSide ]]]!
- 	baseClass := Smalltalk at: baseName asSymbol ifAbsent: [^ nil].
- 	meta
- 		ifTrue: [^ baseClass classSide]
- 		ifFalse: [^ baseClass]!




More information about the Squeak-dev mailing list