IRBuilderTest: CompiledMethod -> Method (CompiledMethod is Squeak class)
authorJan Vrany <jan.vrany@fit.cvut.cz>
Wed, 06 Apr 2011 21:17:27 +0000
changeset 33 9c1e160e9688
parent 32 326e2b5665e1
child 34 4c372f8296b9
IRBuilderTest: CompiledMethod -> Method (CompiledMethod is Squeak class)
IRBuilderTest.st
--- a/IRBuilderTest.st	Sun Apr 11 10:58:42 2010 +0000
+++ b/IRBuilderTest.st	Wed Apr 06 21:17:27 2011 +0000
@@ -208,7 +208,7 @@
                 returnTop;
                 ir.
     aCompiledMethod := iRMethod compiledCode.
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
+    self assert:(aCompiledMethod isKindOf:Method).
     self 
         assert:((aCompiledMethod valueWithReceiver:nil arguments:#()) = true).
 !
@@ -225,7 +225,7 @@
                 returnTop;
                 ir.
     aCompiledMethod := irBuilder compiledCode.
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
+    self assert:(aCompiledMethod isKindOf:Method).
     self 
         assert:((aCompiledMethod valueWithReceiver:(3 @ 4) arguments:#()) = 7).
 
@@ -245,7 +245,7 @@
                 returnTop;
                 ir.
     aCompiledMethod := iRMethod compiledCode.
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
+    self assert:(aCompiledMethod isKindOf:Method).
     self assert:((aCompiledMethod valueWithReceiver:nil arguments:#()) = nil).
 !
 
@@ -263,7 +263,7 @@
                 returnTop;
                 ir.
     aCompiledMethod := iRMethod compiledCode.
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
+    self assert:(aCompiledMethod isKindOf:Method).
     self assert:((aCompiledMethod valueWithReceiver:nil arguments:#()) = nil).
 !
 
@@ -283,7 +283,7 @@
                 returnTop;
                 ir.
     aCompiledMethod := iRMethod compiledCode.
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
+    self assert:(aCompiledMethod isKindOf:Method).
     self assert:((aCompiledMethod valueWithReceiver:nil arguments:#()) = nil).
 !
 
@@ -298,7 +298,7 @@
                 returnTop;
                 ir.
     aCompiledMethod := iRMethod compiledCode.
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
+    self assert:(aCompiledMethod isKindOf:Method).
     self 
         assert:((aCompiledMethod valueWithReceiver:nil arguments:#()) = true).
 
@@ -318,7 +318,7 @@
                 returnTop;
                 ir.
     aCompiledMethod := iRMethod compiledCode.
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
+    self assert:(aCompiledMethod isKindOf:Method).
     self 
         assert:((aCompiledMethod valueWithReceiver:nil arguments:#()) = false).
 
@@ -335,7 +335,7 @@
                 returnTop;
                 ir.
     aCompiledMethod := iRMethod compiledCode.
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
+    self assert:(aCompiledMethod isKindOf:Method).
     self assert:((aCompiledMethod valueWithReceiver:nil arguments:#()) 
                 = #( #test 4 #you )).
 !
@@ -350,7 +350,7 @@
                 returnTop;
                 ir.
     aCompiledMethod := iRMethod compiledCode.
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
+    self assert:(aCompiledMethod isKindOf:Method).
     self 
         assert:((aCompiledMethod valueWithReceiver:nil arguments:#()) = true).
 !
@@ -365,7 +365,7 @@
                 returnTop;
                 ir.
     aCompiledMethod := iRMethod compiledCode.
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
+    self assert:(aCompiledMethod isKindOf:Method).
     self assert:((aCompiledMethod valueWithReceiver:nil arguments:#()) = $e).
 !
 
@@ -379,7 +379,7 @@
                 returnTop;
                 ir.
     aCompiledMethod := iRMethod compiledCode.
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
+    self assert:(aCompiledMethod isKindOf:Method).
     self assert:((aCompiledMethod valueWithReceiver:nil arguments:#()) = 2.0).
 
     "Modified: / 03-11-2008 / 08:39:52 / Jan Vrany <vranyj1@fel.cvut.cz>"
@@ -395,7 +395,7 @@
                 returnTop;
                 ir.
     aCompiledMethod := iRMethod compiledCode.
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
+    self assert:(aCompiledMethod isKindOf:Method).
     self assert:((aCompiledMethod valueWithReceiver:nil arguments:#()) = 2).
 !
 
@@ -409,7 +409,7 @@
                 returnTop;
                 ir.
     aCompiledMethod := iRMethod compiledCode.
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
+    self assert:(aCompiledMethod isKindOf:Method).
     self assert:((aCompiledMethod valueWithReceiver:4 arguments:#()) = nil).
 !
 
@@ -423,7 +423,7 @@
                 returnTop;
                 ir.
     aCompiledMethod := iRMethod compiledCode.
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
+    self assert:(aCompiledMethod isKindOf:Method).
     self 
         assert:((aCompiledMethod valueWithReceiver:nil arguments:#()) = 'hello').
 !
@@ -438,7 +438,7 @@
                 returnTop;
                 ir.
     aCompiledMethod := iRMethod compiledCode.
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
+    self assert:(aCompiledMethod isKindOf:Method).
     self 
         assert:((aCompiledMethod valueWithReceiver:nil arguments:#()) = #you).
 !
@@ -453,7 +453,7 @@
                 returnTop;
                 ir.
     aCompiledMethod := iRMethod compiledCode.
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
+    self assert:(aCompiledMethod isKindOf:Method).
     self 
         assert:((aCompiledMethod valueWithReceiver:nil arguments:#()) = Object).
 !
@@ -468,7 +468,7 @@
                 returnTop;
                 ir.
     aCompiledMethod := iRMethod compiledCode.
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
+    self assert:(aCompiledMethod isKindOf:Method).
     self assert:((aCompiledMethod valueWithReceiver:nil arguments:#()) 
                 = ArithmeticValue arithmeticSignal).
 
@@ -485,7 +485,7 @@
                 returnTop;
                 ir.
     aCompiledMethod := iRMethod compiledCode.
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
+    self assert:(aCompiledMethod isKindOf:Method).
     self 
         assert:((aCompiledMethod valueWithReceiver:nil arguments:#()) = Smalltalk).
 
@@ -504,7 +504,7 @@
                 returnTop;
                 ir.
     aCompiledMethod := iRMethod compiledCode.
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
+    self assert:(aCompiledMethod isKindOf:Method).
     self 
         assert:((aCompiledMethod valueWithReceiver:nil arguments:#()) = true).
 
@@ -522,7 +522,7 @@
                 ir.
     aCompiledMethod := iRMethod compiledCode.
     receiver := (5 @ 8).
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
+    self assert:(aCompiledMethod isKindOf:Method).
     self assert:((aCompiledMethod valueWithReceiver:receiver arguments:#()) 
                 == receiver).
 !
@@ -539,7 +539,7 @@
                 returnTop;
                 ir.
     aCompiledMethod := iRMethod compiledCode.
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
+    self assert:(aCompiledMethod isKindOf:Method).
     self 
         assert:((aCompiledMethod valueWithReceiver:nil arguments:#( 2 8 )) = 10).
 !
@@ -555,7 +555,7 @@
                 returnTop;
                 ir.
     aCompiledMethod := iRMethod compiledCode.
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
+    self assert:(aCompiledMethod isKindOf:Method).
     self assert:((aCompiledMethod valueWithReceiver:nil arguments:#()) 
                 == UndefinedObject).
 !
@@ -570,7 +570,7 @@
                 returnTop;
                 ir.
     aCompiledMethod := iRMethod compiledCode.
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
+    self assert:(aCompiledMethod isKindOf:Method).
     self assert:((aCompiledMethod valueWithReceiver:5 arguments:#()) = nil).
 !
 
@@ -585,7 +585,7 @@
                 returnTop;
                 ir.
     aCompiledMethod := iRMethod compiledCode.
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
+    self assert:(aCompiledMethod isKindOf:Method).
     self assert:((aCompiledMethod valueWithReceiver:5 arguments:#()) = 5).
 !
 
@@ -607,7 +607,7 @@
                 ir.
     aCompiledMethod := iRMethod compiledCode.
     receiver := Object new.
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
+    self assert:(aCompiledMethod isKindOf:Method).
     self assert:((aCompiledMethod valueWithReceiver:receiver arguments:#()) 
                 isKindOf:ClosureEnvironment)
 !
@@ -627,7 +627,7 @@
     aCompiledMethod := iRMethod compiledCode.
     self class basicAddSelector:#mock1
         withMethod:(self class >> #mock1:with:).
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
+    self assert:(aCompiledMethod isKindOf:Method).
     self 
         assert:(aCompiledMethod valueWithReceiver:(IRBuilderTest new)
                 arguments:#()) = 3.
@@ -650,11 +650,9 @@
     aCompiledMethod := iRMethod compiledCode.
     self class basicAddSelector:#mock1
         withMethod:(self class >> #mock1:with:).
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
-    self 
-        should:[
-            (aCompiledMethod valueWithReceiver:(IRBuilderTest new) arguments:#())
-        ]
+    self assert:(aCompiledMethod isKindOf:Method).
+    self should:
+            [ (aCompiledMethod valueWithReceiver:(IRBuilderTest new) arguments:#()) ]
         raise:Error.
     self class basicRemoveSelector:#mock1.
 
@@ -672,11 +670,9 @@
                 returnTop;
                 ir.
     aCompiledMethod := iRMethod compiledCode.
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
-    self 
-        should:[
-            (aCompiledMethod valueWithReceiver:(IRBuilderTest new) arguments:#())
-        ]
+    self assert:(aCompiledMethod isKindOf:Method).
+    self should:
+            [ (aCompiledMethod valueWithReceiver:(IRBuilderTest new) arguments:#()) ]
         raise:Error.
 
     "Modified: / 11-06-2008 / 16:09:12 / Jan Vrany <vranyj1@fel.cvut.cz>"
@@ -694,7 +690,7 @@
                 returnTop;
                 ir.
     aCompiledMethod := iRMethod compiledCode.
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
+    self assert:(aCompiledMethod isKindOf:Method).
     aCompiledMethod valueWithReceiver:nil arguments:#().
     self assert:(IRBuilderTest testToPush = 4).
     IRBuilderTest testToPush:nil.
@@ -712,7 +708,7 @@
                 returnTop;
                 ir.
     aCompiledMethod := iRMethod compiledCode.
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
+    self assert:(aCompiledMethod isKindOf:Method).
     self assert:((aCompiledMethod valueWithReceiver:nil arguments:#()) = 34).
 
     "Modified: / 11-06-2008 / 16:24:43 / Jan Vrany <vranyj1@fel.cvut.cz>"
@@ -735,7 +731,7 @@
                 returnTop;
                 ir.
     aCompiledMethod := iRMethod compiledCode.
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
+    self assert:(aCompiledMethod isKindOf:Method).
     self assert:((aCompiledMethod valueWithReceiver:nil arguments:#()) 
                 isKindOf:ClosureEnvironment).
 
@@ -758,7 +754,7 @@
                 returnTop;
                 ir.
     aCompiledMethod := iRMethod compiledCode.
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
+    self assert:(aCompiledMethod isKindOf:Method).
     self assert:((aCompiledMethod valueWithReceiver:nil arguments:#()) = nil).
 
     "Created: / 03-11-2008 / 13:34:50 / Jan Vrany <vranyj1@fel.cvut.cz>"
@@ -772,31 +768,30 @@
     irBuilder := (IRBuilder new)
                 numRargs:1;
                 addTemps:#( #self );
-                pushBlockUsingBuilder:[:builder | 
+                pushBlockUsingBuilder:
+                        [:builder | 
                         builder
                             numRargs:1;
                             addTemps:#( #barg1 );
-                            pushBlockUsingBuilder:[:builder|
-                                builder
-                                    numRargs: 1;
-                                    addTemps: #( #barg2 );
-                                    pushTemp: #barg2;
-                                    returnTop
-                            ];
-                            pushTemp: #barg1;
-                            send: #value:;
-                            returnTop
-                    ];
-                pushLiteral: 22;
+                            pushBlockUsingBuilder:
+                                    [:builder | 
+                                    builder
+                                        numRargs:1;
+                                        addTemps:#( #barg2 );
+                                        pushTemp:#barg2;
+                                        returnTop ];
+                            pushTemp:#barg1;
+                            send:#value:;
+                            returnTop ];
+                pushLiteral:22;
                 send:#value:;
                 returnTop;
                 ir.
-    "
-        irBuilder ir
+     "
+     irBuilder ir
     "
-
     aCompiledMethod := irBuilder compiledCode.
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
+    self assert:(aCompiledMethod isKindOf:Method).
     self assert:((aCompiledMethod valueWithReceiver:1 arguments:#()) = 22).
 
     "Created: / 11-05-2009 / 23:04:13 / Jan Vrany <vranyj1@fel.cvut.cz>"
@@ -809,40 +804,39 @@
     irBuilder := (IRBuilder new)
                 numRargs:1;
                 addTemps:#( #self );
-                pushBlockUsingBuilder:[:builder | 
+                pushBlockUsingBuilder:
+                        [:builder | 
                         builder
                             numRargs:1;
                             addTemps:#( #barg1 );
-                            pushBlockUsingBuilder:[:builder|
-                                builder
-                                    numRargs: 1;
-                                    addTemps: #( #barg2 );
-                                    pushTemp: #barg2;
-                                    returnTop
-                            ];
-                            pushTemp: #barg1;
-                            send: #value:;
-                            pushBlockUsingBuilder:[:builder|
-                                builder
-                                    numRargs: 1;
-                                    addTemps: #( #barg2 );
-                                    pushLiteral: -1;
-                                    returnTop
-                            ];
-                            pushTemp: #barg1;
-                            send: #value:;
-                            returnTop
-                    ];
-                pushLiteral: 22;
+                            pushBlockUsingBuilder:
+                                    [:builder | 
+                                    builder
+                                        numRargs:1;
+                                        addTemps:#( #barg2 );
+                                        pushTemp:#barg2;
+                                        returnTop ];
+                            pushTemp:#barg1;
+                            send:#value:;
+                            pushBlockUsingBuilder:
+                                    [:builder | 
+                                    builder
+                                        numRargs:1;
+                                        addTemps:#( #barg2 );
+                                        pushLiteral:-1;
+                                        returnTop ];
+                            pushTemp:#barg1;
+                            send:#value:;
+                            returnTop ];
+                pushLiteral:22;
                 send:#value:;
                 returnTop;
                 ir.
-    "
-        irBuilder ir
+     "
+     irBuilder ir
     "
-
     aCompiledMethod := irBuilder compiledCode.
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
+    self assert:(aCompiledMethod isKindOf:Method).
     self assert:((aCompiledMethod valueWithReceiver:1 arguments:#()) = -1).
 
     "Created: / 23-03-2010 / 21:43:49 / Jan Vrany <jan.vrany@fit.cvut.cz>"
@@ -854,23 +848,22 @@
     irBuilder := (IRBuilder new)
                 numRargs:1;
                 addTemps:#( #self );
-                pushBlockUsingBuilder:[:builder | 
+                pushBlockUsingBuilder:
+                        [:builder | 
                         builder
                             numRargs:1;
                             addTemps:#( #barg1 );
                             pushTemp:#barg1;
-                            returnTop
-                    ];
+                            returnTop ];
                 pushLiteral:22;
                 send:#value:;
                 returnTop;
                 ir.
-    "
-        irBuilder ir
+     "
+     irBuilder ir
     "
-
     aCompiledMethod := irBuilder compiledCode.
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
+    self assert:(aCompiledMethod isKindOf:Method).
     self assert:((aCompiledMethod valueWithReceiver:1 arguments:#()) = 22).
 
     "Created: / 30-03-2009 / 14:26:18 / Jan Vrany <vranyj1@fel.cvut.cz>"
@@ -883,24 +876,23 @@
     irBuilder := (IRBuilder new)
                 numRargs:1;
                 addTemps:#( #self );
-                pushBlockUsingBuilder:[:builder | 
+                pushBlockUsingBuilder:
+                        [:builder | 
                         builder
                             numRargs:0;
                             addTemps:#( #bvar1 );
-                            pushLiteral: 22;
+                            pushLiteral:22;
                             storeTemp:#bvar1;
-                            pushTemp: #bvar1;
-                            returnTop
-                    ];
+                            pushTemp:#bvar1;
+                            returnTop ];
                 send:#value;
                 returnTop;
                 ir.
-    "
-        irBuilder ir
+     "
+     irBuilder ir
     "
-
     aCompiledMethod := irBuilder compiledCode.
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
+    self assert:(aCompiledMethod isKindOf:Method).
     self assert:((aCompiledMethod valueWithReceiver:1 arguments:#()) = 22).
 
     "Created: / 30-03-2009 / 23:03:48 / Jan Vrany <vranyj1@fel.cvut.cz>"
@@ -912,25 +904,24 @@
     irBuilder := (IRBuilder new)
                 numRargs:1;
                 addTemps:#( #self );
-                pushLiteral: false;
-                pushLiteral: true;
-                jumpAheadTo: #end if: false;
-                pushBlockUsingBuilder:[:builder | 
+                pushLiteral:false;
+                pushLiteral:true;
+                jumpAheadTo:#end if:false;
+                pushBlockUsingBuilder:
+                        [:builder | 
                         builder
-                            numRargs: 0;
-                            pushLiteral: true;
-                            returnTop
-                    ];
-                send: #value;
-                jumpAheadTarget: #end;
+                            numRargs:0;
+                            pushLiteral:true;
+                            returnTop ];
+                send:#value;
+                jumpAheadTarget:#end;
                 returnTop;
                 ir.
-    "
-        irBuilder ir
+     "
+     irBuilder ir
     "
-
     aCompiledMethod := irBuilder compiledCode.
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
+    self assert:(aCompiledMethod isKindOf:Method).
     self assert:((aCompiledMethod valueWithReceiver:1 arguments:#()) = true).
 
     "Created: / 13-05-2009 / 11:24:48 / Jan Vrany <vranyj1@fel.cvut.cz>"
@@ -941,32 +932,32 @@
 
     irBuilder := (IRBuilder new)
                 numRargs:1;
-                addTemps:#( #self);
-               pushBlockUsingBuilder:[:builder | 
+                addTemps:#( #self );
+                pushBlockUsingBuilder:
+                        [:builder | 
                         builder
-                            numRargs:0;  
-                            pushLiteral: 1;
-                            pushLiteral: 0;
-                            send: #/;
-                            pushLiteral: false;
-                            remoteReturn
-                    ];
-                pushLiteralVariable: #Error;
-                pushBlockUsingBuilder:[:builder|
-                    builder
-                        numRargs:0;
-                        pushLiteral: true;
-                        remoteReturn];
-                send: #on:do:;
-                pushLiteral: false;
+                            numRargs:0;
+                            pushLiteral:1;
+                            pushLiteral:0;
+                            send:#'/';
+                            pushLiteral:false;
+                            remoteReturn ];
+                pushLiteralVariable:#Error;
+                pushBlockUsingBuilder:
+                        [:builder | 
+                        builder
+                            numRargs:0;
+                            pushLiteral:true;
+                            remoteReturn ];
+                send:#on:do:;
+                pushLiteral:false;
                 returnTop;
                 ir.
-    "
-        irBuilder ir
+     "
+     irBuilder ir
     "
-
     aCompiledMethod := irBuilder compiledCode.
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
+    self assert:(aCompiledMethod isKindOf:Method).
     self assert:((aCompiledMethod valueWithReceiver:1 arguments:#()) = true).
 
     "Created: / 11-05-2009 / 21:53:19 / Jan Vrany <vranyj1@fel.cvut.cz>"
@@ -977,31 +968,31 @@
 
     irBuilder := (IRBuilder new)
                 numRargs:1;
-                addTemps:#( #self);
-               pushBlockUsingBuilder:[:builder | 
+                addTemps:#( #self );
+                pushBlockUsingBuilder:
+                        [:builder | 
                         builder
-                            numRargs:0;  
-                            pushLiteral: 1;
-                            pushLiteral: 0;
-                            send: #/;
-                            pushLiteral: false;
-                            returnTop
-                    ];
-                pushLiteralVariable: #Error;
-                pushBlockUsingBuilder:[:builder|
-                    builder
-                        numRargs:0;
-                        pushLiteral: true;
-                        returnTop];
-                send: #on:do:;
+                            numRargs:0;
+                            pushLiteral:1;
+                            pushLiteral:0;
+                            send:#'/';
+                            pushLiteral:false;
+                            returnTop ];
+                pushLiteralVariable:#Error;
+                pushBlockUsingBuilder:
+                        [:builder | 
+                        builder
+                            numRargs:0;
+                            pushLiteral:true;
+                            returnTop ];
+                send:#on:do:;
                 returnTop;
                 ir.
-    "
-        irBuilder ir
+     "
+     irBuilder ir
     "
-
     aCompiledMethod := irBuilder compiledCode.
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
+    self assert:(aCompiledMethod isKindOf:Method).
     self assert:((aCompiledMethod valueWithReceiver:1 arguments:#()) = true).
 
     "Created: / 11-05-2009 / 21:53:25 / Jan Vrany <vranyj1@fel.cvut.cz>"
@@ -1011,28 +1002,27 @@
     |aCompiledMethod irBuilder|
 
     irBuilder := (IRBuilder new)
-                    numRargs: 1;
-                    addTemps: #(self i);
-                    pushTemp: #i;
-                    pushLiteral: 3;
-                    pushReceiver;
-
-                    pushBlockUsingBuilder: [ :builder | 
+                numRargs:1;
+                addTemps:#( #self #i );
+                pushTemp:#i;
+                pushLiteral:3;
+                pushReceiver;
+                pushBlockUsingBuilder:
+                        [:builder | 
                         builder
-                            numRargs: 0;
-                            addTemps: #();
-                            pushTemp: #i;
-                            returnTop.
-                    ];
-                    returnTop;
-                    ir.
+                            numRargs:0;
+                            addTemps:#();
+                            pushTemp:#i;
+                            returnTop. ];
+                returnTop;
+                ir.
+     "
+     irBuilder ir
     "
-        irBuilder ir
-    "
-
     aCompiledMethod := irBuilder compiledCode.
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
-    self assert:((aCompiledMethod valueWithReceiver:1 arguments:#()) isKindOf: Block).
+    self assert:(aCompiledMethod isKindOf:Method).
+    self assert:((aCompiledMethod valueWithReceiver:1 arguments:#()) 
+                isKindOf:Block).
 
     "Created: / 11-05-2009 / 21:55:30 / Jan Vrany <vranyj1@fel.cvut.cz>"
 !
@@ -1042,24 +1032,23 @@
 
     irBuilder := (IRBuilder new)
                 numRargs:1;
-                addTemps:#( #self #a);
-                pushLiteral: 22;
-                storeTemp: #a;
-                pushBlockUsingBuilder:[:builder | 
+                addTemps:#( #self #a );
+                pushLiteral:22;
+                storeTemp:#a;
+                pushBlockUsingBuilder:
+                        [:builder | 
                         builder
                             numRargs:0;
-                            pushTemp: #a;
-                            returnTop
-                    ];
+                            pushTemp:#a;
+                            returnTop ];
                 send:#value;
                 returnTop;
                 ir.
-    "
-        irBuilder ir
+     "
+     irBuilder ir
     "
-
     aCompiledMethod := irBuilder compiledCode.
-    self assert:(aCompiledMethod isKindOf:CompiledMethod).
+    self assert:(aCompiledMethod isKindOf:Method).
     self assert:((aCompiledMethod valueWithReceiver:1 arguments:#()) = 22).
 
     "Created: / 30-03-2009 / 23:05:00 / Jan Vrany <vranyj1@fel.cvut.cz>"