mirror of
https://github.com/m-labs/artiq.git
synced 2024-12-25 03:08:27 +08:00
transforms.inferencer: don't crash on partially-inferred binary expressions.
This commit is contained in:
parent
6938036b28
commit
5dcf936f4e
@ -348,6 +348,10 @@ class Inferencer(algorithm.Visitor):
|
||||
pred, kind = builtins.is_list, "list"
|
||||
else:
|
||||
assert False
|
||||
|
||||
if types.is_var(other.type):
|
||||
return
|
||||
|
||||
if not pred(other.type):
|
||||
printer = types.TypePrinter()
|
||||
note1 = diagnostic.Diagnostic("note",
|
||||
|
Loading…
Reference in New Issue
Block a user