Status: FixReviewNeeded
Owner:
[hidden email]
Labels: Type-Bug
New issue 5879 by
[hidden email]: Add missing initialization in
Decompiler>>decompileBlock:
http://code.google.com/p/pharo/issues/detail?id=5879Nicolas Cellier uploaded a new version of Compiler to project The Trunk:
http://source.squeak.org/trunk/Compiler-nice.229.mcz==================== Summary ====================
Name: Compiler-nice.229
Author: nice
Time: 22 April 2012, 4:35:27.085 pm
UUID: 1d6c6093-e2bb-4dce-92c0-3a4713132c54
Ancestors: Compiler-eem.228
Add missing initialization in Decompiler>>decompileBlock:
=============== Diff against Compiler-eem.228 ===============
Item was changed:
----- Method: Decompiler>>decompileBlock: (in category 'public access')
-----
decompileBlock: aBlock
"Decompile aBlock, returning the result as a BlockNode.
Show temp names from source if available."
"Decompiler new decompileBlock: [3 + 4]"
| startpc end homeClass blockNode methodNode home |
(home := aBlock home) ifNil: [^ nil].
method := home method.
(homeClass := home methodClass) == #unknown ifTrue: [^ nil].
aBlock isClosure ifTrue:
[(methodNode := method decompileWithTemps)
ifNil: [^nil]
ifNotNil: [methodNode nodesDo: [:node| node pc =
aBlock startpc ifTrue: [^node]]].
^self error: 'cannot find block node matching aBlock'].
constructor := self constructorForMethod: aBlock method.
self withTempNames: method methodNode tempNames.
self initSymbols: homeClass.
startpc := aBlock startpc.
end := aBlock endPC.
stack := OrderedCollection new: method frameSize.
+ lastJumpIfPcStack := OrderedCollection new.
caseExits := OrderedCollection new.
statements := OrderedCollection new: 20.
super method: method pc: startpc - 5.
blockNode := self blockTo: end.
stack isEmpty ifFalse: [self error: 'stack not empty'].
^blockNode statements first!
_______________________________________________
Pharo-bugtracker mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-bugtracker