core: Deduplicate values in `Literal`
Matches the behavior with `typing.Literal`.
This commit is contained in:
parent
f742d0c32d
commit
bf830f216e
|
@ -388,7 +388,7 @@ impl Unifier {
|
|||
loc: Option<Location>,
|
||||
) -> Type {
|
||||
let ty_enum = TypeEnum::TLiteral {
|
||||
values: values.clone(),
|
||||
values: values.into_iter().dedup().collect(),
|
||||
loc
|
||||
};
|
||||
self.add_ty(ty_enum)
|
||||
|
|
Loading…
Reference in New Issue