aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlon Zakai <azakai@mozilla.com>2010-12-04 21:35:33 -0800
committerAlon Zakai <azakai@mozilla.com>2010-12-04 21:35:33 -0800
commite1caf733964f01be61839ac75c95993908104a7e (patch)
treea2b018093f0a138b0e572920fbbcd8847312cc4b
parent7e332b116c930f1bd12a4da10ac1cf4ab21ab024 (diff)
fix 2 bugs in variable analyzer
-rw-r--r--src/analyzer.js4
-rw-r--r--src/library.js5
2 files changed, 7 insertions, 2 deletions
diff --git a/src/analyzer.js b/src/analyzer.js
index c57b3be9..9b29c72c 100644
--- a/src/analyzer.js
+++ b/src/analyzer.js
@@ -239,8 +239,8 @@ function analyzer(data, givenTypes) {
});
// Normal variables
- walkJSON(func.lines, function(item) {
- if (item && item.intertype == 'assign') {
+ func.lines.forEach(function(item) {
+ if (item.intertype in set('assign', 'fastgetelementptrload')) {
func.variables[item.ident] = {
ident: item.ident,
type: item.value.type,
diff --git a/src/library.js b/src/library.js
index 370a5b1a..3a673b45 100644
--- a/src/library.js
+++ b/src/library.js
@@ -498,6 +498,11 @@ var Library = {
// TODO
return 0;
},
+
+ // stat.h
+
+ __01fstat64_: function() { return -1 },
+
};
load('library_sdl.js');