mirror of
https://github.com/erg-lang/erg.git
synced 2025-08-04 10:49:54 +00:00
fix: in
operator
* remove `In` trait, `__in__`, `__notin__` function * desugar to `__contains__` * impl Collection for Array, Set, Tuple
This commit is contained in:
parent
4f93c393c0
commit
2e9fb48f2e
19 changed files with 154 additions and 142 deletions
|
@ -767,9 +767,7 @@ impl<'c, 'q, 'l, L: Locational> Dereferencer<'c, 'q, 'l, L> {
|
|||
};
|
||||
if sub_t == super_t {
|
||||
Ok(sub_t)
|
||||
}
|
||||
// REVIEW: Even if type constraints can be satisfied, implementation may not exist
|
||||
else if is_subtype {
|
||||
} else if is_subtype {
|
||||
match self.variance {
|
||||
// ?T(<: Sup) --> Sup (Sup != Obj), because completion will not work if Never is selected.
|
||||
// ?T(:> Never, <: Obj) --> Never
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue