A new version of SystemEditor was added to project SystemEditor: http://www.squeaksource.com/SystemEditor/SystemEditor-mtf.114.mcz
==================== Summary ====================
Name: SystemEditor-mtf.114 Author: mtf Time: 13 August 2008, 12:06:44 am UUID: a0b5f178-9445-43fc-8da6-f3b84d6bd41b Ancestors: SystemEditor-mtf.113, SystemEditor-mtf.111
merged the stable branch (107-111) with the unstable branch (112-113)
=============== Diff against SystemEditor-mtf.113 ===============
Item was added: + ----- Method: MetaclassEditor>>indexIfCompact (in category 'reflecting') ----- + indexIfCompact + self subject ifNotNil: [^ self subject indexIfCompact]. + ^ 0!
Item was added: + ----- Method: ClassOrganizer>>edClassComment:stamp: (in category '*SystemEditor-workaround') ----- + edClassComment: aString stamp: aStamp + "Set the comment and stamp directly, with no checks.This works around a silly check in ClassOrganizer>>classComment:stamp: in Croquet. This check raises an error if the subject is either nil or a metaclass. The check does not exist in Squeak 3.8 and above" + ^ super classComment: aString stamp: aStamp!
Item was changed: ----- Method: OrganizationEditor>>build (in category 'building') ----- build | result | self subject. subject ifNil: [ result := ClassOrganizer defaultList: #()] ifNotNil: [ result := ClassOrganizer defaultList: self subject elementArray. self subject categories ifNotNilDo: [:categories | categories do: [:ea | result classifyAll: (subject listAtCategoryNamed: ea) under: ea]]]. classEditor edMethodsDo: [:ea | result classify: ea selector under: (self categoryOfElement: ea selector)]. + result + edClassComment: self commentRemoteStr + stamp: self commentStamp. - result classComment: self commentRemoteStr stamp: self commentStamp. ^ result!
Item was changed: ----- Method: ClassEditor>>edName:superclassEditor:type:instVarString:classVarString:poolImports:category: (in category 'building') ----- edName: aSymbol superclassEditor: anEditor type: typeOfClass instVarString: instString classVarString: classString poolImports: poolString category: catString | scanner | scanner := Scanner new. name := aSymbol. + self superclass: anEditor. - superEditor := anEditor. type := typeOfClass. category := catString. instVarNames := scanner scanFieldNames: instString. classVarNames := scanner scanFieldNames: classString. sharedPools := (scanner scanFieldNames: poolString) collect: [:ea | system edResolve: ea asSymbol]!
Item was changed: ----- Method: MetaclassEditor>>instSize (in category 'reflecting') ----- instSize "Override the implemenation in Behavior, so that when inspecting the ClassEditor, it will look like a regular Class"
self isDebuggingAsEditor ifTrue: [^ super instSize]. + ^ self instVarNames size + (self edSuperclass + ifNil: [0] ifNotNilDo: [:ed | ed instSize])! - ^ self allInstVarNames size!
Item was changed: ----- Method: MethodEditor>>compileFor: (in category 'building') ----- compileFor: aClassEditor + [ | node method | node := aClassEditor compilerClass new compile: source in: aClassEditor product notifying: requestor ifFail: nil. node encoder requestor: self. method := node generate: #(0 0 0 0). method selector: node selector. + ^ method + ] on: SyntaxErrorNotification do: [:ex | + "Let the user install the fixed code into the system" + ex defaultAction. + "Now fetch and use that code instead" + source := aClassEditor product sourceCodeAt: self selector ifAbsent: [^ nil]. + ^ aClassEditor product compiledMethodAt: self selector + ]! - ^ method!
Item was changed: ----- Method: ClassEditor>>edBuild (in category 'building') ----- edBuild | meta | meta := self class edBuild. product := subject ifNil: [meta new] ifNotNil: [meta adoptInstance: subject from: subject class]. product superclass: self edSuperclass; setFormat: self format; setName: self name; setInstVarNames: self instVarNames; classPoolFrom: self; instVarNamed: #sharedPools put: self sharedPools; organization: self organization build. + product methodDictionary: MethodDictionary new. self decoratorsDo: [:ea | ea buildFor: self]. + + "Class methods should be compiled before instance methods, + since #compilerClass may be among the class methods" + self class methods buildFor: self class. + self methods buildFor: self. - product methodDictionary: self methodDictionary. - product class methodDictionary: self class methodDictionary. ^product!
Item was changed: ----- Method: MetaclassEditor>>allInstVarNames (in category 'reflecting') ----- allInstVarNames "specialized in order to enable debugger to show as self" - | vars | self isDebuggingAsEditor ifTrue: [^ super allInstVarNames]. + ^ self edSuperclass + ifNil: [self instVarNames copy] + ifNotNil: [self edSuperclass allInstVarNames, self instVarNames]! - - vars := self subject ifNil: [ #() ] ifNotNil: [ self instVarNames ]. - - ^ superclass == nil - ifTrue: [ vars copy] "Guarantee a copy is answered." - ifFalse: [ self superclass allInstVarNames , vars ]. - !
Item was changed: ----- Method: MetaclassEditor>>edSuperclass (in category 'building') ----- edSuperclass ^ superEditor ifNil: [self subject superclass] + ifNotNil: [superEditor product]! - ifNotNil: [superEditor subject]!
Item was added: + ----- Method: MetaclassEditor>>typeOfClass (in category 'reflecting') ----- + typeOfClass + ^ #normal!
Item was changed: ----- Method: MethodDictionaryEditor>>buildFor: (in category 'editing') ----- buildFor: aClassEditor | result old | + result := aClassEditor product methodDictionary. - result := MethodDictionary new. self subject keysAndValuesDo: [:selector :cm | (self selectorIsModified: selector) ifFalse: [result at: selector put: (self recompile: selector from: cm for: aClassEditor)]]. additions keysAndValuesDo: [:selector :mm | old := self subject at: selector ifAbsent: [nil]. result at: selector put: (mm compileFrom: old for: aClassEditor)]. ^ result !
packages@lists.squeakfoundation.org