Status: New
Owner: ----
New issue 3741 by
[hidden email]: Decompiler hangs
http://code.google.com/p/pharo/issues/detail?id=3741this method can't work, because ParseNode can't understand remoteTemps:
popIntoTemporaryVariable: offset
| maybeTVTag tempVector start |
maybeTVTag := stack last.
((maybeTVTag isMemberOf: Association)
and: [maybeTVTag key == #pushNewArray]) ifTrue:
[blockStartsToTempVars notNil "implies we were intialized with temp
names."
ifTrue: "Use the provided temps"
[[(tempVector := tempVars at: offset + 1 ifAbsent: [ParseNode
basicNew]) isTemp
and: [tempVector isIndirectTempVector
and: [tempVector remoteTemps size = maybeTVTag value size]]] assert]
ifFalse: "Synthesize some remote temps"
[tempVector := maybeTVTag value.
offset + 1 <= tempVars size
ifTrue:
[start := 2.
tempVector at: 1 put: (tempVars at: offset + 1)]
ifFalse:
[tempVars := (Array new: offset + 1)
replaceFrom: 1
to: tempVars size
with: tempVars.
start := 1].
start to: tempVector size do:
[:i|
tempVector
at: i
put: (constructor
codeTemp: numLocalTemps + offset + i - 1
named: 't', (tempVarCount + i) printString)].
tempVars at: offset + 1 put: (constructor codeRemoteTemp: offset + 1
remoteTemps: tempVector)].
tempVarCount := tempVarCount + maybeTVTag value size.
stack removeLast.
^self].
self pushTemporaryVariable: offset; doStore: statements
I get the problem in PharoInstantMessenger ver.4 if you wanna test.
It's really annoying to spend a day on that, just because a variable is
declared in a block.
For a 30yo language, it sucks