compiler/PPCCodeGenerator.st
changeset 534 a949c4fe44df
parent 532 132d7898a2a1
child 538 16e8536f5cfb
--- a/compiler/PPCCodeGenerator.st	Wed Aug 26 23:34:48 2015 +0100
+++ b/compiler/PPCCodeGenerator.st	Sat Aug 29 07:56:14 2015 +0100
@@ -2,7 +2,7 @@
 
 "{ NameSpace: Smalltalk }"
 
-PPCPass subclass:#PPCCodeGenerator
+PPCPassVisitor subclass:#PPCCodeGenerator
 	instanceVariableNames:'codeGen'
 	classVariableNames:''
 	poolDictionaries:''
@@ -210,13 +210,16 @@
     context isNil ifTrue:[ 
         PPCCompilationError new signal: 'oops, no context set, use #context: before running a pass!!'.
     ].
-    codeGen options: context options.
-    codeGen clazz: context parserClass.  
-    entry := self visit: ir.
-    context parserClass propertyAt:#rootMethod put:entry. 
+    context options generate ifTrue:[
+        codeGen options: context options.
+        codeGen clazz: context parserClass.  
+        entry := self visit: ir.
+        context parserClass propertyAt:#rootMethod put:entry. 
+    ].
     ^ ir
 
     "Created: / 26-08-2015 / 22:38:58 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+    "Modified: / 04-09-2015 / 10:18:25 / Jan Vrany <jan.vrany@fit.cvut.cz>"
 ! !
 
 !PPCCodeGenerator methodsFor:'support'!