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
It is possible to write a macro which checks whether types like (-> Integer String) are equal, but for types like (-> (Maybe Integer) String), this is harder because the user can later introduce more datatypes which the macro doesn't know about.
I propose to provide a primitive macro which determines whether two types are known to be equal, or known to be apart. If the answer depends on what type unification variables will eventually resolve to, the macro is of course stuck until enough information is available.
The text was updated successfully, but these errors were encountered:
This seems like it's clearly useful. But rather than a macro, I'd make it an effect in the macro monad. That is, a type likeType -> Type -> Macro Bool rather than Syntax -> Macro Syntax, and not bound in a transformer environment.
It is possible to write a macro which checks whether types like
(-> Integer String)
are equal, but for types like(-> (Maybe Integer) String)
, this is harder because the user can later introduce more datatypes which the macro doesn't know about.I propose to provide a primitive macro which determines whether two types are known to be equal, or known to be apart. If the answer depends on what type unification variables will eventually resolve to, the macro is of course stuck until enough information is available.
The text was updated successfully, but these errors were encountered: