mirror of
https://github.com/erg-lang/erg.git
synced 2025-08-04 10:49:54 +00:00
fix: refinement types bugs
This commit is contained in:
parent
5c6ea316f5
commit
1c8da7f049
15 changed files with 178 additions and 168 deletions
|
@ -1,5 +1,4 @@
|
|||
//! test module for `Context`
|
||||
use erg_common::set;
|
||||
use erg_common::traits::StructuralEq;
|
||||
use erg_common::Str;
|
||||
|
||||
|
@ -33,7 +32,7 @@ impl Context {
|
|||
let rhs = refinement(
|
||||
var.clone(),
|
||||
Type::Int,
|
||||
set! { Predicate::eq(var, TyParam::value(1)) },
|
||||
Predicate::eq(var, TyParam::value(1)),
|
||||
);
|
||||
if self.supertype_of(&lhs, &rhs) {
|
||||
Ok(())
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue