Commit 1cf94671 authored by di68kap's avatar di68kap
Browse files

parse.Compiler: ValueError is raised if a compiler method returns None

parent 27fbcf5e
......@@ -2031,6 +2031,8 @@ class Compiler:
result = compiler(node)
if result is None:
raise ValueError('%s failed to return a valid compilation result!' % str(compiler))
# # the following statement makes sure that the error_flag
# # is propagated early on. Otherwise it is redundant, because
# # the __call__ method globally propagates the node's error_flag
Supports Markdown
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