Squeak Source to VW

Marco Paga seaside at marco-paga.de
Sat Jul 3 16:45:40 UTC 2004


Hi.
I tried to file-in the exported source but everytime I get the exception: "The 
identifier has no binding". I attached the source where somethig goes wrong.
The message #binding is handled by BindingReference. It checks for nil and 
raises the exception.
After the filein I have some classes in the image with no methods and the 
correct namespace is created too.

If anybody has an idea what could have gone wrong I would be happy. Right now 
I'm thinking of recreating the whole logic...

Regards
Marco


NameSpace>>defineClass: className superclass: superID indexedType: typeName 
private: isPrivate
	instanceVariableNames: iVars classInstanceVariableNames: ciVars
	imports: pools category: category attributes: attributes

	| superclass approved class cbr mbr |
	superID == nil
		ifTrue: [superclass := nil]
==>		ifFalse: [superID binding isForClass
			ifTrue: [superclass := superID value]
			ifFalse: [self error: (#SuperclassMustBeAClass << #dialogs >> 'The 
superclass of a class must also be a class')]].
	Behavior checkLegalBehaviorType: typeName.
	approved := SystemUtils
			validateClassName: className
			for: nil.
	approved == nil ifTrue: [^nil].
	cbr := (BehaviorBuilderRecord forName: approved in: self)
			superclass: superclass;
			instVarString: iVars;
			category: category;
			attributes: attributes;
			behaviorType: typeName;
			importString: pools;
			private: isPrivate.
	(mbr := MetaclassBuilderRecord new)
		forInstance: cbr;
		instVarString: ciVars.
	class := ClassBuilder new
		addRecord: cbr;
		addRecord: mbr;
		reviseSystem.
	^class

-- 
The future is a process, not a destination.
The future is not a noun, it's a verb.

-- Bruce Sterling



More information about the Squeak-dev mailing list