diff options
author | Alon Zakai <azakai@mozilla.com> | 2011-01-12 22:25:12 -0800 |
---|---|---|
committer | Alon Zakai <azakai@mozilla.com> | 2011-01-12 22:25:12 -0800 |
commit | 60122ddc2e157b1cf117e6e098a2fc336c92d5a7 (patch) | |
tree | 82aa2ab43ab15b4813e983f83294772db5ffcad7 /src | |
parent | 907ab2c11fe3c98e2c261812a414bce9558c2fab (diff) |
make sure our warning about show-annotations always shows up
Diffstat (limited to 'src')
-rw-r--r-- | src/intertyper.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/intertyper.js b/src/intertyper.js index bf51cd8e..efe34216 100644 --- a/src/intertyper.js +++ b/src/intertyper.js @@ -270,7 +270,7 @@ function intertyper(data, parseFunctions, baseLineNum) { return 'Bitcast'; if (tokensLength >= 3 && token0Text == 'getelementptr') return 'GEP'; - if (tokensLength >= 3 && token0Text == 'alloca') + if (tokensLength >= 2 && token0Text == 'alloca') return 'Alloca'; if (tokensLength >= 3 && token0Text == 'extractvalue') return 'ExtractValue'; @@ -583,7 +583,7 @@ function intertyper(data, parseFunctions, baseLineNum) { processItem: function(item) { item.intertype = 'alloca'; item.allocatedType = item.tokens[1].text; - item.allocatedNum = Runtime.isNumberType(item.tokens[3].text) ? toNiceIdent(item.tokens[4].text) : 1; + item.allocatedNum = (item.tokens.length > 3 && Runtime.isNumberType(item.tokens[3].text)) ? toNiceIdent(item.tokens[4].text) : 1; item.type = addPointing(item.tokens[1].text); // type of pointer we will get item.type2 = item.tokens[1].text; // value we will create, and get a pointer to this.forwardItem(item, 'Reintegrator'); |