[Newcompiler] When Decompiler2 is used?
Mathieu Suen
mathk.sue at gmail.com
Tue Mar 20 16:01:14 UTC 2007
Hi,
It seems to me that the Decompiler of the NewCompiler is never used?
Compiler>>#decompilerClass
"Answer a decompiler class appropriate for this Compiler."
^ Preferences compileUseNewCompiler
ifTrue: [FakeDecompiler]
ifFalse: [Decompiler]
But FakeCompiler use only Decompiler:
FakeCompiler>>#decompile:in:method:
"Answer a MethodNode that is the root of the parse tree for the
argument, aMethod, which is the CompiledMethod associated with the
message, aSelector. Variables are determined with respect to the
argument, aClass."
| source |
^ (source := aMethod getSourceFromFile)
ifNil: [Decompiler new decompile: selector in: aClass method:
aMethod ]
ifNotNil: [aMethod parserClass new parse: source class: aMethod
methodClass]
Math
More information about the Newcompiler
mailing list