mirror of
https://github.com/erg-lang/erg.git
synced 2025-09-29 04:24:43 +00:00
Fix bugs
This commit is contained in:
parent
afcf21787d
commit
ae15f95191
7 changed files with 159 additions and 57 deletions
|
@ -797,11 +797,11 @@ impl Context {
|
|||
TypeSpec::PreDeclTy(predecl) => {
|
||||
Ok(self.instantiate_predecl_t(predecl, opt_decl_t, tmp_tv_ctx)?)
|
||||
}
|
||||
TypeSpec::And(lhs, rhs) => Ok(self.union(
|
||||
TypeSpec::And(lhs, rhs) => Ok(self.intersection(
|
||||
&self.instantiate_typespec(lhs, opt_decl_t, tmp_tv_ctx, mode)?,
|
||||
&self.instantiate_typespec(rhs, opt_decl_t, tmp_tv_ctx, mode)?,
|
||||
)),
|
||||
TypeSpec::Or(lhs, rhs) => Ok(self.intersection(
|
||||
TypeSpec::Or(lhs, rhs) => Ok(self.union(
|
||||
&self.instantiate_typespec(lhs, opt_decl_t, tmp_tv_ctx, mode)?,
|
||||
&self.instantiate_typespec(rhs, opt_decl_t, tmp_tv_ctx, mode)?,
|
||||
)),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue