summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAlon Zakai <alonzakai@gmail.com>2016-01-26 11:33:18 -0800
committerAlon Zakai <alonzakai@gmail.com>2016-01-26 11:33:18 -0800
commitc2f0a42a36ea4a6047c483aa51d9fced98b96ada (patch)
treee397023d3d026941fbbe10ef69b3fcc7b52d3eed /src
parentd9bb568c5693e042676bfd2d8797270dc6e55922 (diff)
parent5e0a7f42b82f1096a41a51ada2a370e0f465ea93 (diff)
downloadbinaryen-c2f0a42a36ea4a6047c483aa51d9fced98b96ada.tar.gz
binaryen-c2f0a42a36ea4a6047c483aa51d9fced98b96ada.tar.bz2
binaryen-c2f0a42a36ea4a6047c483aa51d9fced98b96ada.zip
Merge pull request #143 from Lichtso/master
Ignore meta data emitted by clang on Mac OS X
Diffstat (limited to 'src')
-rw-r--r--src/s2wasm.h12
1 files changed, 11 insertions, 1 deletions
diff --git a/src/s2wasm.h b/src/s2wasm.h
index 54682e4b0..82675df1b 100644
--- a/src/s2wasm.h
+++ b/src/s2wasm.h
@@ -387,7 +387,8 @@ private:
if (!*s) break;
if (*s != '.') break;
s++;
- if (match("file")) parseFile();
+ if (parseVersionMin());
+ else if (match("file")) parseFile();
else if (match("globl")) parseGlobl();
else if (match("type")) parseType();
else {
@@ -414,6 +415,15 @@ private:
skipWhitespace();
}
+ bool parseVersionMin() {
+ if (match("watchos_version_min") || match("tvos_version_min") || match("ios_version_min") || match("macosx_version_min")) {
+ s = strchr(s, '\n');
+ skipWhitespace();
+ return true;
+ } else
+ return false;
+ }
+
void parseFunction() {
if (debug) dump("func");
Name name = getStrToSep();