Open TWal opened 5 months ago
A minimization inspired by guido (https://github.com/FStarLang/FStar/issues/3309#issuecomment-2165639699)
type rec1 = {
x:int;
}
type rec2 = {
x:int;
}
val bind : #a:Type -> #b:Type -> a -> (a -> b) -> b
let bind x f = f x
let test (r:rec1): int =
bind r (fun n ->
n.x
)
Similar to #3309, but using record disambiguation to bamboozle the type inference of F*:
Note that this time this is not using fancy dependent types, it's something we could write in any functional programming language (with record field name disambiguation)