[Newcompiler] When Decompiler2 is used?

Marcus Denker denker at iam.unibe.ch
Tue Mar 20 19:55:12 UTC 2007


On 20.03.2007, at 17:01, Mathieu Suen wrote:

> Hi,
>
> It seems to me that the Decompiler of the NewCompiler is never used?
>

Yes, it's broken right now, so it uses the fake decompiler (which is  
actually
just compiling the source).

This really needs to be fixed...

	Marcus

> 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

-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 3947 bytes
Desc: not available
Url : http://lists.squeakfoundation.org/pipermail/newcompiler/attachments/20070320/5b69eed6/smime.bin


More information about the Newcompiler mailing list