Commit 304342fd authored by Nils Goroll's avatar Nils Goroll

vmodtool should actually raise an error for unknown keywords

... like 'Unknown keyword: $Init' for 4.0 vcc files.
parent 2c4cb155
......@@ -870,14 +870,6 @@ def runmain(inputvcc, outputname="vcc_if"):
#######################################################################
# Break into sections
keywords = {
"$Module": True,
"$Function": True,
"$Object": True,
"$Method": True,
"$Event": True,
}
sl = []
sc = FileSection()
sl.append(sc)
......@@ -885,7 +877,7 @@ def runmain(inputvcc, outputname="vcc_if"):
ln += 1
l = lines.pop(0)
j = l.split()
if len(j) > 0 and j[0] in keywords:
if len(j) > 0 and re.match("^\$", j[0]):
sc = FileSection()
sl.append(sc)
sc.add_line(ln, l)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment