diff options
author | Alon Zakai <alonzakai@gmail.com> | 2016-01-31 08:44:51 -0800 |
---|---|---|
committer | Alon Zakai <alonzakai@gmail.com> | 2016-01-31 08:44:51 -0800 |
commit | 48832b5d4dbd06f6f7f6afca5822055f219a7392 (patch) | |
tree | 2984a348b88913fbff96d4b27507ae777f1d487d | |
parent | ae918ff5f5746398d0393cf871f6208e582b82d2 (diff) | |
download | binaryen-48832b5d4dbd06f6f7f6afca5822055f219a7392.tar.gz binaryen-48832b5d4dbd06f6f7f6afca5822055f219a7392.tar.bz2 binaryen-48832b5d4dbd06f6f7f6afca5822055f219a7392.zip |
handle initial comments in wast splitting
-rwxr-xr-x | check.py | 5 |
1 files changed, 5 insertions, 0 deletions
@@ -174,6 +174,11 @@ def split_wast(wast): i = 0 while i >= 0: start = wast.find('(', i) + skip = wast.find(';', i) + if skip >= 0 and skip < start and skip + 1 < len(wast): + if wast[skip+1] == ';': + i = wast.find('\n', i) + 1 + continue if start < 0: break i = to_end(start + 1) chunk = wast[start:i] |