You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
take the cat.compose(morphism, inverse) in inverse_left as example.
elaboration will insert ApImplicit based on the type of morphism,
get cat.compose(implicit x1, implicit x2, morphism, implicit x3, inverse).
solve it, get cat.compose(implicit dom, implicit dom, morphism, implicit dom, inverse),
we write it like this, but actually solved value will not be substituted in place,
but be saved in the env of the closure as x1 => dom.
now dom is in scope, but only have type dom: cat.Object, no value, thus it is a neutral variable.
in the following code block, fulfilling class type Isomorphism(cat, x.object, y.object)
will provide the value of dom -- x.object.
during fulfilling class type, when evaluating inverse_left's type,
we have dom => x.object and x1 => dom in scope,
evaluate variable x1 will only get the neutral variable dom,
but not going further to get the value of dom -- x.object,
this is the problem.
It might be not enough for substInEnv to only handle variable,
maybe we also need to handle all Values
-- like deep walk
-- maybe called advanceByEnv (v.s. advanceBySolution).
The text was updated successfully, but these errors were encountered:
Problem:
cat.compose
is aPiImplicit
.cat.compose(morphism, inverse)
ininverse_left
as example.ApImplicit
based on the type ofmorphism
,get
cat.compose(implicit x1, implicit x2, morphism, implicit x3, inverse)
.cat.compose(implicit dom, implicit dom, morphism, implicit dom, inverse)
,we write it like this, but actually solved value will not be substituted in place,
but be saved in the
env
of the closure asx1 => dom
.dom
is in scope, but only have typedom: cat.Object
, no value, thus it is a neutral variable.Isomorphism(cat, x.object, y.object)
will provide the value of
dom
--x.object
.inverse_left
's type,we have
dom => x.object
andx1 => dom
in scope,evaluate variable
x1
will only get the neutral variabledom
,but not going further to get the value of
dom
--x.object
,this is the problem.
Solution 1:
Use
substInEnv
.It might be not enough for
substInEnv
to only handle variable,maybe we also need to handle all
Values
-- like deep walk
-- maybe called
advanceByEnv
(v.s.advanceBySolution
).The text was updated successfully, but these errors were encountered: