Unify call's fx var with that of the enclosing function

This commit is contained in:
Agus Zubiaga 2024-10-07 21:14:08 -03:00
parent 7871ba182d
commit 5a5abe3bc5
No known key found for this signature in database
23 changed files with 246 additions and 41 deletions

View file

@ -101,6 +101,7 @@ impl FlatDecodable {
| Content::FlexAbleVar(_, _)
| Content::RigidAbleVar(_, _) => Err(UnboundVar),
Content::LambdaSet(_) | Content::ErasedLambda => Err(Underivable),
Content::Pure | Content::Effectful => Err(Underivable),
}
}

View file

@ -135,6 +135,7 @@ impl FlatEncodable {
| Content::FlexAbleVar(_, _)
| Content::RigidAbleVar(_, _) => Err(UnboundVar),
Content::LambdaSet(_) | Content::ErasedLambda => Err(Underivable),
Content::Pure | Content::Effectful => Err(Underivable),
}
}

View file

@ -146,6 +146,7 @@ impl FlatHash {
| Content::FlexAbleVar(_, _)
| Content::RigidAbleVar(_, _) => Err(UnboundVar),
Content::LambdaSet(_) | Content::ErasedLambda => Err(Underivable),
Content::Pure | Content::Effectful => Err(Underivable),
}
}

View file

@ -178,7 +178,9 @@ impl FlatInspectable {
| Content::FlexAbleVar(_, _)
| Content::RigidAbleVar(_, _)
| Content::LambdaSet(_)
| Content::ErasedLambda => {
| Content::ErasedLambda
| Content::Pure
| Content::Effectful => {
unreachable!("There must have been a bug in the solver, because we're trying to derive Inspect on a non-concrete type.");
}
}