Browse Source

Recompile.

Herbert Vojčík 9 years ago
parent
commit
122869fa79

+ 12 - 9
src/Compiler-IR.js

@@ -455,7 +455,7 @@ function $IRTempDeclaration(){return $globals.IRTempDeclaration||(typeof IRTempD
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
-var $1,$2,$3,$5,$4,$6;
+var $1,$2,$3,$5,$4,$6,$8,$7;
 $1=$recv($IRClosure())._new();
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 $ctx1.sendIdx["new"]=1;
@@ -484,10 +484,12 @@ $recv($4)._do_((function(each){
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx2) {
 //>>excludeEnd("ctx");
-$6=$recv($IRTempDeclaration())._new();
-$recv($6)._name_($recv(each)._name());
-$recv($6)._scope_($recv(aNode)._scope());
-return $recv(closure)._add_($recv($6)._yourself());
+$6=closure;
+$8=$recv($IRTempDeclaration())._new();
+$recv($8)._name_($recv(each)._name());
+$recv($8)._scope_($recv(aNode)._scope());
+$7=$recv($8)._yourself();
+return $recv($6)._add_($7);
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 $ctx2.sendIdx["add:"]=1;
 //>>excludeEnd("ctx");
@@ -783,7 +785,7 @@ function $IRVerbatim(){return $globals.IRVerbatim||(typeof IRVerbatim=="undefine
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
-var $2,$3,$4,$1,$6,$5,$7,$9,$10,$11,$8,$12,$14,$13,$15,$17,$19,$20,$18,$21,$16,$22;
+var $2,$3,$4,$1,$6,$5,$7,$9,$10,$11,$8,$12,$14,$13,$15,$17,$19,$20,$18,$21,$16,$23,$22;
 $2=$recv($IRMethod())._new();
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 $ctx1.sendIdx["new"]=1;
@@ -904,9 +906,10 @@ $recv($15)._add_($16);
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 $ctx1.sendIdx["add:"]=3;
 //>>excludeEnd("ctx");
-$22=$recv($IRVerbatim())._new();
-$recv($22)._source_("");
-$recv($15)._add_($recv($22)._yourself());
+$23=$recv($IRVerbatim())._new();
+$recv($23)._source_("");
+$22=$recv($23)._yourself();
+$recv($15)._add_($22);
 };
 return self._method();
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);

+ 5 - 4
src/Compiler-Inlining.js

@@ -2337,7 +2337,7 @@ function $IRReturn(){return $globals.IRReturn||(typeof IRReturn=="undefined"?nil
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
-var $1,$3,$2,$4,$5;
+var $1,$3,$2,$4,$6,$5;
 closure=(
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 $ctx1.supercall = true, 
@@ -2368,9 +2368,10 @@ $4=$recv(statements)._last();
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 $ctx2.sendIdx["last"]=3;
 //>>excludeEnd("ctx");
-$5=$recv($IRReturn())._new();
-$recv($5)._add_($recv($recv(statements)._last())._copy());
-return $recv($4)._replaceWith_($recv($5)._yourself());
+$6=$recv($IRReturn())._new();
+$recv($6)._add_($recv($recv(statements)._last())._copy());
+$5=$recv($6)._yourself();
+return $recv($4)._replaceWith_($5);
 };
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});

+ 6 - 4
src/Compiler-Semantic.js

@@ -1006,7 +1006,7 @@ function $PseudoVar(){return $globals.PseudoVar||(typeof PseudoVar=="undefined"?
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
-var $1,$2,$receiver;
+var $1,$2,$4,$3,$receiver;
 $1=self["@pseudoVars"];
 if(($receiver = $1) == null || $receiver.isNil){
 self["@pseudoVars"]=$recv($Dictionary())._new();
@@ -1015,9 +1015,11 @@ $recv($recv($Smalltalk())._pseudoVariableNames())._do_((function(each){
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx2) {
 //>>excludeEnd("ctx");
-$2=$recv($PseudoVar())._on_(each);
-$recv($2)._scope_(self._methodScope());
-return $recv(self["@pseudoVars"])._at_put_(each,$recv($2)._yourself());
+$2=self["@pseudoVars"];
+$4=$recv($PseudoVar())._on_(each);
+$recv($4)._scope_(self._methodScope());
+$3=$recv($4)._yourself();
+return $recv($2)._at_put_(each,$3);
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,2)});
 //>>excludeEnd("ctx");

+ 36 - 24
src/Compiler-Tests.js

@@ -162,11 +162,13 @@ function $Object(){return $globals.Object||(typeof Object=="undefined"?nil:Objec
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
-var $1;
+var $3,$2,$1;
 ast=self._parse_forClass_("foo <consolee.log(1)>",$Object());
-$1=self._astPCNodeVisitor();
-$recv($1)._visit_(ast);
-self._assert_($recv($recv($1)._currentNode())._isJSStatementNode());
+$3=self._astPCNodeVisitor();
+$recv($3)._visit_(ast);
+$2=$recv($3)._currentNode();
+$1=$recv($2)._isJSStatementNode();
+self._assert_($1);
 return self;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 }, function($ctx1) {$ctx1.fill(self,"testJSStatementNode",{ast:ast,visitor:visitor},$globals.ASTPCNodeVisitorTest)});
@@ -192,11 +194,13 @@ function $Object(){return $globals.Object||(typeof Object=="undefined"?nil:Objec
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
-var $1;
+var $3,$2,$1;
 ast=self._parse_forClass_("foo self asString yourself. ^ self asBoolean",$Object());
-$1=self._astPCNodeVisitorForSelector_("yourself");
-$recv($1)._visit_(ast);
-self._assert_equals_($recv($recv($1)._currentNode())._selector(),"yourself");
+$3=self._astPCNodeVisitorForSelector_("yourself");
+$recv($3)._visit_(ast);
+$2=$recv($3)._currentNode();
+$1=$recv($2)._selector();
+self._assert_equals_($1,"yourself");
 return self;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 }, function($ctx1) {$ctx1.fill(self,"testMessageSend",{ast:ast},$globals.ASTPCNodeVisitorTest)});
@@ -222,11 +226,13 @@ function $Object(){return $globals.Object||(typeof Object=="undefined"?nil:Objec
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
-var $1;
+var $3,$2,$1;
 ast=self._parse_forClass_("foo true ifTrue: [ [ self asString yourself ] value.  ]. ^ self asBoolean",$Object());
-$1=self._astPCNodeVisitorForSelector_("yourself");
-$recv($1)._visit_(ast);
-self._assert_equals_($recv($recv($1)._currentNode())._selector(),"yourself");
+$3=self._astPCNodeVisitorForSelector_("yourself");
+$recv($3)._visit_(ast);
+$2=$recv($3)._currentNode();
+$1=$recv($2)._selector();
+self._assert_equals_($1,"yourself");
 return self;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 }, function($ctx1) {$ctx1.fill(self,"testMessageSendWithBlocks",{ast:ast},$globals.ASTPCNodeVisitorTest)});
@@ -252,7 +258,7 @@ function $Object(){return $globals.Object||(typeof Object=="undefined"?nil:Objec
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
-var $3,$4,$2,$1,$5;
+var $3,$4,$2,$1,$7,$6,$5;
 ast=self._parse_forClass_("foo true ifTrue: [ self asString yourself ]. ^ self asBoolean",$Object());
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 $ctx1.sendIdx["parse:forClass:"]=1;
@@ -279,9 +285,11 @@ self._assert_equals_($1,"yourself");
 $ctx1.sendIdx["assert:equals:"]=1;
 //>>excludeEnd("ctx");
 ast=self._parse_forClass_("foo true ifTrue: [ self asString yourself ]. ^ self asBoolean",$Object());
-$5=self._astPCNodeVisitorForSelector_("asBoolean");
-$recv($5)._visit_(ast);
-self._assert_equals_($recv($recv($5)._currentNode())._selector(),"asBoolean");
+$7=self._astPCNodeVisitorForSelector_("asBoolean");
+$recv($7)._visit_(ast);
+$6=$recv($7)._currentNode();
+$5=$recv($6)._selector();
+self._assert_equals_($5,"asBoolean");
 return self;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 }, function($ctx1) {$ctx1.fill(self,"testMessageSendWithInlining",{ast:ast},$globals.ASTPCNodeVisitorTest)});
@@ -307,11 +315,13 @@ function $Object(){return $globals.Object||(typeof Object=="undefined"?nil:Objec
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
-var $1;
+var $3,$2,$1;
 ast=self._parse_forClass_("foo ^ self",$Object());
-$1=self._astPCNodeVisitor();
-$recv($1)._visit_(ast);
-self._assert_($recv($recv($1)._currentNode())._isNil());
+$3=self._astPCNodeVisitor();
+$recv($3)._visit_(ast);
+$2=$recv($3)._currentNode();
+$1=$recv($2)._isNil();
+self._assert_($1);
 return self;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 }, function($ctx1) {$ctx1.fill(self,"testNoMessageSend",{ast:ast},$globals.ASTPCNodeVisitorTest)});
@@ -337,11 +347,13 @@ function $Object(){return $globals.Object||(typeof Object=="undefined"?nil:Objec
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
-var $1;
+var $3,$2,$1;
 ast=self._parse_forClass_("foo <console.log(1)>",$Object());
-$1=self._astPCNodeVisitor();
-$recv($1)._visit_(ast);
-self._assert_($recv($recv($1)._currentNode())._isJSStatementNode());
+$3=self._astPCNodeVisitor();
+$recv($3)._visit_(ast);
+$2=$recv($3)._currentNode();
+$1=$recv($2)._isJSStatementNode();
+self._assert_($1);
 return self;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 }, function($ctx1) {$ctx1.fill(self,"testPC",{ast:ast,visitor:visitor},$globals.ASTPCNodeVisitorTest)});

+ 50 - 34
src/Kernel-Classes.js

@@ -456,11 +456,13 @@ function $ClassCommentChanged(){return $globals.ClassCommentChanged||(typeof Cla
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
-var $1;
+var $1,$3,$2;
 self._basicAt_put_("comment",aString);
-$1=$recv($ClassCommentChanged())._new();
-$recv($1)._theClass_(self);
-$recv($recv($SystemAnnouncer())._current())._announce_($recv($1)._yourself());
+$1=$recv($SystemAnnouncer())._current();
+$3=$recv($ClassCommentChanged())._new();
+$recv($3)._theClass_(self);
+$2=$recv($3)._yourself();
+$recv($1)._announce_($2);
 return self;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 }, function($ctx1) {$ctx1.fill(self,"comment:",{aString:aString},$globals.Behavior)});
@@ -1272,12 +1274,14 @@ function $MethodRemoved(){return $globals.MethodRemoved||(typeof MethodRemoved==
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
-var $1;
+var $1,$3,$2;
 self._basicRemoveCompiledMethod_(aMethod);
 self._removeProtocolIfEmpty_($recv(aMethod)._protocol());
-$1=$recv($MethodRemoved())._new();
-$recv($1)._method_(aMethod);
-$recv($recv($SystemAnnouncer())._current())._announce_($recv($1)._yourself());
+$1=$recv($SystemAnnouncer())._current();
+$3=$recv($MethodRemoved())._new();
+$recv($3)._method_(aMethod);
+$2=$recv($3)._yourself();
+$recv($1)._announce_($2);
 return self;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 }, function($ctx1) {$ctx1.fill(self,"removeCompiledMethod:",{aMethod:aMethod},$globals.Behavior)});
@@ -1740,7 +1744,7 @@ function $ClassMoved(){return $globals.ClassMoved||(typeof ClassMoved=="undefine
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
-var $2,$1,$3,$4;
+var $2,$1,$3,$4,$6,$5;
 $2=self._package();
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 $ctx1.sendIdx["package"]=1;
@@ -1757,10 +1761,12 @@ $ctx1.sendIdx["organization"]=1;
 //>>excludeEnd("ctx");
 $recv($3)._removeElement_(self);
 $recv($recv(aPackage)._organization())._addElement_(self);
-$4=$recv($ClassMoved())._new();
-$recv($4)._theClass_(self);
-$recv($4)._oldPackage_(oldPackage);
-$recv($recv($SystemAnnouncer())._current())._announce_($recv($4)._yourself());
+$4=$recv($SystemAnnouncer())._current();
+$6=$recv($ClassMoved())._new();
+$recv($6)._theClass_(self);
+$recv($6)._oldPackage_(oldPackage);
+$5=$recv($6)._yourself();
+$recv($4)._announce_($5);
 return self;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 }, function($ctx1) {$ctx1.fill(self,"package:",{aPackage:aPackage,oldPackage:oldPackage},$globals.Class)});
@@ -2495,12 +2501,14 @@ function $ClassDefinitionChanged(){return $globals.ClassDefinitionChanged||(type
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
-var $1;
+var $1,$3,$2;
 self._basicClass_instanceVariableNames_(aClass,ivarNames);
 self._setupClass_(aClass);
-$1=$recv($ClassDefinitionChanged())._new();
-$recv($1)._theClass_(aClass);
-$recv($recv($SystemAnnouncer())._current())._announce_($recv($1)._yourself());
+$1=$recv($SystemAnnouncer())._current();
+$3=$recv($ClassDefinitionChanged())._new();
+$recv($3)._theClass_(aClass);
+$2=$recv($3)._yourself();
+$recv($1)._announce_($2);
 return self;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 }, function($ctx1) {$ctx1.fill(self,"class:instanceVariableNames:",{aClass:aClass,ivarNames:ivarNames},$globals.ClassBuilder)});
@@ -2527,12 +2535,14 @@ function $ClassAdded(){return $globals.ClassAdded||(typeof ClassAdded=="undefine
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
-var $1;
+var $1,$3,$2;
 newClass=self._addSubclassOf_named_instanceVariableNames_package_($recv(aClass)._superclass(),className,$recv(aClass)._instanceVariableNames(),$recv($recv(aClass)._package())._name());
 self._copyClass_to_(aClass,newClass);
-$1=$recv($ClassAdded())._new();
-$recv($1)._theClass_(newClass);
-$recv($recv($SystemAnnouncer())._current())._announce_($recv($1)._yourself());
+$1=$recv($SystemAnnouncer())._current();
+$3=$recv($ClassAdded())._new();
+$recv($3)._theClass_(newClass);
+$2=$recv($3)._yourself();
+$recv($1)._announce_($2);
 return newClass;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 }, function($ctx1) {$ctx1.fill(self,"copyClass:named:",{aClass:aClass,className:className,newClass:newClass},$globals.ClassBuilder)});
@@ -2727,7 +2737,7 @@ function $ClassMigrated(){return $globals.ClassMigrated||(typeof ClassMigrated==
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
-var $1,$2;
+var $1,$2,$4,$3;
 tmp="new*".__comma(className);
 oldClass=$recv($recv($Smalltalk())._globals())._at_(className);
 newClass=self._addSubclassOf_named_instanceVariableNames_package_(aClass,tmp,aCollection,packageName);
@@ -2773,10 +2783,12 @@ return self._migrateClass_superclass_(each,newClass);
 //>>excludeEnd("ctx");
 }));
 self._basicRemoveClass_(oldClass);
-$2=$recv($ClassMigrated())._new();
-$recv($2)._theClass_(newClass);
-$recv($2)._oldClass_(oldClass);
-$recv($recv($SystemAnnouncer())._current())._announce_($recv($2)._yourself());
+$2=$recv($SystemAnnouncer())._current();
+$4=$recv($ClassMigrated())._new();
+$recv($4)._theClass_(newClass);
+$recv($4)._oldClass_(oldClass);
+$3=$recv($4)._yourself();
+$recv($2)._announce_($3);
 return newClass;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 }, function($ctx1) {$ctx1.fill(self,"migrateClassNamed:superclass:instanceVariableNames:package:",{className:className,aClass:aClass,aCollection:aCollection,packageName:packageName,oldClass:oldClass,newClass:newClass,tmp:tmp},$globals.ClassBuilder)});
@@ -2828,12 +2840,14 @@ function $ClassRenamed(){return $globals.ClassRenamed||(typeof ClassRenamed=="un
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
-var $1;
+var $1,$3,$2;
 self._basicRenameClass_to_(aClass,className);
 $recv(aClass)._recompile();
-$1=$recv($ClassRenamed())._new();
-$recv($1)._theClass_(aClass);
-$recv($recv($SystemAnnouncer())._current())._announce_($recv($1)._yourself());
+$1=$recv($SystemAnnouncer())._current();
+$3=$recv($ClassRenamed())._new();
+$recv($3)._theClass_(aClass);
+$2=$recv($3)._yourself();
+$recv($1)._announce_($2);
 return self;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 }, function($ctx1) {$ctx1.fill(self,"renameClass:to:",{aClass:aClass,className:className},$globals.ClassBuilder)});
@@ -2907,7 +2921,7 @@ function $ClassAdded(){return $globals.ClassAdded||(typeof ClassAdded=="undefine
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
-var $1,$2,$3,$receiver;
+var $1,$2,$3,$5,$4,$receiver;
 $1=self._instanceVariableNamesFor_(ivarNames);
 if(($receiver = packageName) == null || $receiver.isNil){
 $2="unclassified";
@@ -2916,9 +2930,11 @@ $2=packageName;
 };
 newClass=self._addSubclassOf_named_instanceVariableNames_package_(aClass,className,$1,$2);
 self._setupClass_(newClass);
-$3=$recv($ClassAdded())._new();
-$recv($3)._theClass_(newClass);
-$recv($recv($SystemAnnouncer())._current())._announce_($recv($3)._yourself());
+$3=$recv($SystemAnnouncer())._current();
+$5=$recv($ClassAdded())._new();
+$recv($5)._theClass_(newClass);
+$4=$recv($5)._yourself();
+$recv($3)._announce_($4);
 return newClass;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 }, function($ctx1) {$ctx1.fill(self,"superclass:subclass:instanceVariableNames:package:",{aClass:aClass,className:className,ivarNames:ivarNames,packageName:packageName,newClass:newClass},$globals.ClassBuilder)});

+ 32 - 22
src/Kernel-Infrastructure.js

@@ -623,7 +623,7 @@ function $ProtocolAdded(){return $globals.ProtocolAdded||(typeof ProtocolAdded==
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
-var $1;
+var $1,$3,$2;
 (
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 $ctx1.supercall = true, 
@@ -632,10 +632,12 @@ $ctx1.supercall = true,
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 $ctx1.supercall = false;
 //>>excludeEnd("ctx");;
-$1=$recv($ProtocolAdded())._new();
-$recv($1)._protocol_(aString);
-$recv($1)._theClass_(self._theClass());
-$recv($recv($SystemAnnouncer())._current())._announce_($recv($1)._yourself());
+$1=$recv($SystemAnnouncer())._current();
+$3=$recv($ProtocolAdded())._new();
+$recv($3)._protocol_(aString);
+$recv($3)._theClass_(self._theClass());
+$2=$recv($3)._yourself();
+$recv($1)._announce_($2);
 return self;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 }, function($ctx1) {$ctx1.fill(self,"addElement:",{aString:aString},$globals.ClassOrganizer)});
@@ -661,7 +663,7 @@ function $ProtocolRemoved(){return $globals.ProtocolRemoved||(typeof ProtocolRem
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
-var $1;
+var $1,$3,$2;
 (
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 $ctx1.supercall = true, 
@@ -670,10 +672,12 @@ $ctx1.supercall = true,
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 $ctx1.supercall = false;
 //>>excludeEnd("ctx");;
-$1=$recv($ProtocolRemoved())._new();
-$recv($1)._protocol_(aString);
-$recv($1)._theClass_(self._theClass());
-$recv($recv($SystemAnnouncer())._current())._announce_($recv($1)._yourself());
+$1=$recv($SystemAnnouncer())._current();
+$3=$recv($ProtocolRemoved())._new();
+$recv($3)._protocol_(aString);
+$recv($3)._theClass_(self._theClass());
+$2=$recv($3)._yourself();
+$recv($1)._announce_($2);
 return self;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 }, function($ctx1) {$ctx1.fill(self,"removeElement:",{aString:aString},$globals.ClassOrganizer)});
@@ -807,11 +811,13 @@ function $PackageClean(){return $globals.PackageClean||(typeof PackageClean=="un
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
-var $1;
+var $1,$3,$2;
 self["@dirty"]=false;
-$1=$recv($PackageClean())._new();
-$recv($1)._package_(self);
-$recv($recv($SystemAnnouncer())._current())._announce_($recv($1)._yourself());
+$1=$recv($SystemAnnouncer())._current();
+$3=$recv($PackageClean())._new();
+$recv($3)._package_(self);
+$2=$recv($3)._yourself();
+$recv($1)._announce_($2);
 return self;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 }, function($ctx1) {$ctx1.fill(self,"beClean",{},$globals.Package)});
@@ -837,11 +843,13 @@ function $PackageDirty(){return $globals.PackageDirty||(typeof PackageDirty=="un
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
-var $1;
+var $1,$3,$2;
 self["@dirty"]=true;
-$1=$recv($PackageDirty())._new();
-$recv($1)._package_(self);
-$recv($recv($SystemAnnouncer())._current())._announce_($recv($1)._yourself());
+$1=$recv($SystemAnnouncer())._current();
+$3=$recv($PackageDirty())._new();
+$recv($3)._package_(self);
+$2=$recv($3)._yourself();
+$recv($1)._announce_($2);
 return self;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 }, function($ctx1) {$ctx1.fill(self,"beDirty",{},$globals.Package)});
@@ -3244,15 +3252,17 @@ function $ClassRemoved(){return $globals.ClassRemoved||(typeof ClassRemoved=="un
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
-var $1,$2;
+var $1,$2,$4,$3;
 $1=$recv(aClass)._isMetaclass();
 if($core.assert($1)){
 self._error_($recv($recv(aClass)._asString()).__comma(" is a Metaclass and cannot be removed!"));
 };
 self._deleteClass_(aClass);
-$2=$recv($ClassRemoved())._new();
-$recv($2)._theClass_(aClass);
-$recv($recv($SystemAnnouncer())._current())._announce_($recv($2)._yourself());
+$2=$recv($SystemAnnouncer())._current();
+$4=$recv($ClassRemoved())._new();
+$recv($4)._theClass_(aClass);
+$3=$recv($4)._yourself();
+$recv($2)._announce_($3);
 return self;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 }, function($ctx1) {$ctx1.fill(self,"removeClass:",{aClass:aClass},$globals.SmalltalkImage)});

+ 10 - 8
src/Kernel-Methods.js

@@ -1053,16 +1053,18 @@ function $MethodMoved(){return $globals.MethodMoved||(typeof MethodMoved=="undef
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
-var $1,$2,$receiver;
+var $1,$3,$2,$4,$receiver;
 oldProtocol=self._protocol();
 self._basicAt_put_("protocol",aString);
-$1=$recv($MethodMoved())._new();
-$recv($1)._method_(self);
-$recv($1)._oldProtocol_(oldProtocol);
-$recv($recv($SystemAnnouncer())._current())._announce_($recv($1)._yourself());
-$2=self._methodClass();
-if(($receiver = $2) == null || $receiver.isNil){
-$2;
+$1=$recv($SystemAnnouncer())._current();
+$3=$recv($MethodMoved())._new();
+$recv($3)._method_(self);
+$recv($3)._oldProtocol_(oldProtocol);
+$2=$recv($3)._yourself();
+$recv($1)._announce_($2);
+$4=self._methodClass();
+if(($receiver = $4) == null || $receiver.isNil){
+$4;
 } else {
 var methodClass;
 methodClass=$receiver;

+ 41 - 32
src/Kernel-Tests.js

@@ -2755,7 +2755,7 @@ var self=this;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
-var $2,$4,$3,$5,$1,$6,$9,$8,$10,$11,$7,$12,$15,$14,$17,$16,$18,$13,$20,$21,$22,$19,$23,$24;
+var $2,$4,$3,$5,$1,$6,$9,$8,$10,$11,$7,$12,$15,$14,$17,$16,$18,$13,$20,$21,$22,$19,$23,$25,$24;
 $2=self._collection();
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 $ctx1.sendIdx["collection"]=1;
@@ -2865,9 +2865,10 @@ $23=self._collectionWithNewValue();
 $ctx1.sendIdx["collectionWithNewValue"]=1;
 //>>excludeEnd("ctx");
 self._assert_equals_($19,$23);
-$24=self._sampleNewValueAsCollection();
-$recv($24)._addAll_(self._collection());
-self._assertSameContents_as_($recv($24)._yourself(),self._collectionWithNewValue());
+$25=self._sampleNewValueAsCollection();
+$recv($25)._addAll_(self._collection());
+$24=$recv($25)._yourself();
+self._assertSameContents_as_($24,self._collectionWithNewValue());
 return self;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 }, function($ctx1) {$ctx1.fill(self,"testAddAll",{},$globals.CollectionTest)});
@@ -4240,10 +4241,11 @@ var self=this;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
-var $1;
-$1=self._collection();
-$recv($1)._removeAll();
-self._assert_equals_($recv($1)._yourself(),$recv(self._collectionClass())._new());
+var $2,$1;
+$2=self._collection();
+$recv($2)._removeAll();
+$1=$recv($2)._yourself();
+self._assert_equals_($1,$recv(self._collectionClass())._new());
 return self;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 }, function($ctx1) {$ctx1.fill(self,"testRemoveAll",{},$globals.CollectionTest)});
@@ -5096,15 +5098,16 @@ function $JSON(){return $globals.JSON||(typeof JSON=="undefined"?nil:JSON)}
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
-var $1;
+var $2,$1;
 jsNull=$recv($JSON())._parse_("null");
 self._samplesDo_((function(index,value){
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx2) {
 //>>excludeEnd("ctx");
-$1=self._collection();
-$recv($1)._at_put_(index,jsNull);
-return self._assert_equals_($recv($1)._indexOf_(jsNull),index);
+$2=self._collection();
+$recv($2)._at_put_(index,jsNull);
+$1=$recv($2)._indexOf_(jsNull);
+return self._assert_equals_($1,index);
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 }, function($ctx2) {$ctx2.fillBlock({index:index,value:value},$ctx1,1)});
 //>>excludeEnd("ctx");
@@ -5301,7 +5304,7 @@ var self=this;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
-var $2,$3,$4,$1,$5,$7,$8,$9,$6,$10,$11;
+var $2,$3,$4,$1,$5,$7,$8,$9,$6,$10,$12,$11;
 (
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 $ctx1.supercall = true, 
@@ -5360,12 +5363,13 @@ self._assert_equals_($6,$10);
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 $ctx1.sendIdx["assert:equals:"]=2;
 //>>excludeEnd("ctx");
-$11=self._collectionWithNewValue();
+$12=self._collectionWithNewValue();
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 $ctx1.sendIdx["collectionWithNewValue"]=3;
 //>>excludeEnd("ctx");
-$recv($11)._addAll_(self._collection());
-self._assert_equals_($recv($11)._yourself(),self._collectionWithNewValue());
+$recv($12)._addAll_(self._collection());
+$11=$recv($12)._yourself();
+self._assert_equals_($11,self._collectionWithNewValue());
 return self;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 }, function($ctx1) {$ctx1.fill(self,"testAddAll",{},$globals.AssociativeCollectionTest)});
@@ -5658,7 +5662,7 @@ function $Error(){return $globals.Error||(typeof Error=="undefined"?nil:Error)}
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
-var $1,$2,$3,$5,$6,$4,$7;
+var $1,$2,$3,$5,$6,$4,$8,$7;
 self._nonIndexesDo_((function(each){
 var collection;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
@@ -5723,9 +5727,10 @@ return self._deny_($4);
 }, function($ctx2) {$ctx2.fillBlock({index:index,value:value,collection:collection},$ctx1,3)});
 //>>excludeEnd("ctx");
 }));
-$7=self._collectionWithNewValue();
-$recv($7)._removeKey_(self._sampleNewIndex());
-self._assert_equals_($recv($7)._yourself(),self._collection());
+$8=self._collectionWithNewValue();
+$recv($8)._removeKey_(self._sampleNewIndex());
+$7=$recv($8)._yourself();
+self._assert_equals_($7,self._collection());
 return self;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 }, function($ctx1) {$ctx1.fill(self,"testRemoveKey",{},$globals.AssociativeCollectionTest)});
@@ -5749,7 +5754,7 @@ var self=this;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
-var $1,$2,$3,$4,$5,$7,$8,$6,$9;
+var $1,$2,$3,$4,$5,$7,$8,$6,$10,$9;
 self._nonIndexesDo_((function(each){
 var collection;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
@@ -5833,8 +5838,8 @@ return self._deny_($6);
 }, function($ctx2) {$ctx2.fillBlock({index:index,value:value,collection:collection},$ctx1,3)});
 //>>excludeEnd("ctx");
 }));
-$9=self._collectionWithNewValue();
-$recv($9)._removeKey_ifAbsent_(self._sampleNewIndex(),(function(){
+$10=self._collectionWithNewValue();
+$recv($10)._removeKey_ifAbsent_(self._sampleNewIndex(),(function(){
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx2) {
 //>>excludeEnd("ctx");
@@ -5843,7 +5848,8 @@ return self._assert_(false);
 }, function($ctx2) {$ctx2.fillBlock({},$ctx1,5)});
 //>>excludeEnd("ctx");
 }));
-self._assert_equals_($recv($9)._yourself(),self._collection());
+$9=$recv($10)._yourself();
+self._assert_equals_($9,self._collection());
 return self;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 }, function($ctx1) {$ctx1.fill(self,"testRemoveKeyIfAbsent",{},$globals.AssociativeCollectionTest)});
@@ -7492,10 +7498,12 @@ var self=this;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
-var $1;
-$1=self._collection();
-$recv($1)._addFirst_((0));
-self._assert_equals_($recv($recv($1)._yourself())._first(),(0));
+var $3,$2,$1;
+$3=self._collection();
+$recv($3)._addFirst_((0));
+$2=$recv($3)._yourself();
+$1=$recv($2)._first();
+self._assert_equals_($1,(0));
 return self;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 }, function($ctx1) {$ctx1.fill(self,"testAddFirst",{},$globals.ArrayTest)});
@@ -9167,7 +9175,7 @@ var self=this;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
-var $2,$3,$4,$1,$5,$7,$8,$9,$6,$10,$11;
+var $2,$3,$4,$1,$5,$7,$8,$9,$6,$10,$12,$11;
 (
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 $ctx1.supercall = true, 
@@ -9226,12 +9234,13 @@ self._assert_equals_($6,$10);
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 $ctx1.sendIdx["assert:equals:"]=2;
 //>>excludeEnd("ctx");
-$11=self._collectionWithNewValue();
+$12=self._collectionWithNewValue();
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 $ctx1.sendIdx["collectionWithNewValue"]=3;
 //>>excludeEnd("ctx");
-$recv($11)._addAll_(self._collection());
-self._assert_equals_($recv($11)._yourself(),self._collectionWithNewValue());
+$recv($12)._addAll_(self._collection());
+$11=$recv($12)._yourself();
+self._assert_equals_($11,self._collectionWithNewValue());
 return self;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 }, function($ctx1) {$ctx1.fill(self,"testAddAll",{},$globals.SetTest)});

+ 5 - 4
src/Platform-Services.js

@@ -438,16 +438,17 @@ var self=this;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
-var $1,$2,$3,$4;
+var $1,$2,$3,$5,$4;
 $1=self._classBuilder();
 $2=$recv(aClass)._superclass();
 $3=$recv(aClass)._name();
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 $ctx1.sendIdx["name"]=1;
 //>>excludeEnd("ctx");
-$4=$recv($recv(aClass)._instanceVariableNames())._copy();
-$recv($4)._add_(aString);
-$recv($1)._addSubclassOf_named_instanceVariableNames_package_($2,$3,$recv($4)._yourself(),$recv($recv(aClass)._package())._name());
+$5=$recv($recv(aClass)._instanceVariableNames())._copy();
+$recv($5)._add_(aString);
+$4=$recv($5)._yourself();
+$recv($1)._addSubclassOf_named_instanceVariableNames_package_($2,$3,$4,$recv($recv(aClass)._package())._name());
 return self;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 }, function($ctx1) {$ctx1.fill(self,"addInstVarNamed:to:",{aString:aString,aClass:aClass},$globals.Environment)});