Skip to content

Commit

Permalink
Don't update stlWASM.c when wabt keyword file is missing, issue #748.
Browse files Browse the repository at this point in the history
  • Loading branch information
zufuliu committed Jan 19, 2024
1 parent 4768422 commit 3e71802
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions tools/KeywordCore.py
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,8 @@ def BuildKeywordContent(rid, lexer, keywordList, keywordCount=16):
return output, attrList

def UpdateKeywordFile(rid, path, lexer, keywordList, keywordCount=16, suffix=''):
if keywordList is None:
return
attrList = []
if keywordList:
output, attrList = BuildKeywordContent(rid, lexer, keywordList, keywordCount=keywordCount)
Expand Down Expand Up @@ -2529,12 +2531,7 @@ def parse_verilog_api_file(pathList):
def parse_wasm_lexer_keywords(path):
if not os.path.isfile(path):
print('missing file:', path)
return [
('keywords', [], KeywordAttr.Default),
('type', [], KeywordAttr.Default),
('instruction', [], KeywordAttr.Default),
('full instruction',[], KeywordAttr.NoLexer),
]
return None

keywordMap = {
'keywords': [],
Expand Down

0 comments on commit 3e71802

Please sign in to comment.