diff options
author | Alon Zakai <alonzakai@gmail.com> | 2011-09-01 18:40:54 -0700 |
---|---|---|
committer | Alon Zakai <alonzakai@gmail.com> | 2011-09-01 18:40:54 -0700 |
commit | ec9d3de1e8979607c98de5da5c89efa95472c633 (patch) | |
tree | 99dd8b2fb3190cada6df45e51ff81802ba9c1e0b /src/intertyper.js | |
parent | f5bd6fd53be86aef05cd7b072e223e9a1371144a (diff) |
fix intertyper parsing bug
Diffstat (limited to 'src/intertyper.js')
-rw-r--r-- | src/intertyper.js | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/intertyper.js b/src/intertyper.js index 3cdaa45e..5dd395bc 100644 --- a/src/intertyper.js +++ b/src/intertyper.js @@ -634,9 +634,10 @@ function intertyper(data, parseFunctions, baseLineNum) { } item.ident = toNiceIdent(item.ident); if (type === 'invoke') { - cleanOutTokens(LLVM.INVOKE_MODIFIERS, item.tokens, 4); - item.toLabel = toNiceIdent(item.tokens[6].text); - item.unwindLabel = toNiceIdent(item.tokens[9].text); + var toIndex = findTokenText(item, 'to'); + item.toLabel = toNiceIdent(item.tokens[toIndex+2].text); + item.unwindLabel = toNiceIdent(item.tokens[toIndex+5].text); + assert(item.toLabel && item.unwindLabel); } if (item.indent == 2) { // standalone call - not in assign |