Push checkmate through env

This commit is contained in:
Ayaz Hafiz 2023-07-16 09:49:18 -05:00
parent 8097ee3342
commit 87d108eccc
No known key found for this signature in database
GPG key ID: 0E2A37416A25EF58
16 changed files with 190 additions and 29 deletions

View file

@ -1,8 +1,9 @@
use bumpalo::Bump;
use roc_can::{constraint::Constraints, module::ExposedByModule};
use roc_checkmate::with_checkmate;
use roc_derive::SharedDerivedModule;
use roc_types::subs::{Content, Descriptor, Mark, OptVariable, Rank, Subs, Variable};
use roc_unify::unify::Env as UEnv;
use roc_unify::Env as UEnv;
use crate::{FunctionKind, Pools};
@ -93,7 +94,11 @@ impl<'a> InferenceEnv<'a> {
/// Retrieves an environment for unification.
pub fn uenv(&mut self) -> UEnv {
UEnv::new(self.subs)
// TODO(checkmate): pass checkmate through
with_checkmate!(None, {
on => UEnv::new(self.subs, None),
off => UEnv::new(self.subs),
})
}
pub fn as_solve_env(&mut self) -> SolveEnv {