[datatypes.py] Changed ValueError to TypeError
parent
aa8d03d296
commit
df54cf9721
|
@ -31,7 +31,7 @@ class Variable:
|
||||||
if self.type == value.type:
|
if self.type == value.type:
|
||||||
object.__setattr__(self, name, value)
|
object.__setattr__(self, name, value)
|
||||||
else:
|
else:
|
||||||
raise ValueError(
|
raise TypeError(
|
||||||
"Type inequality; cannot assign value of "
|
"Type inequality; cannot assign value of "
|
||||||
f"type {value.type} to variable of type {self.type}"
|
f"type {value.type} to variable of type {self.type}"
|
||||||
)
|
)
|
||||||
|
|
Loading…
Reference in New Issue