This repository has been archived by the owner on Oct 18, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 16
Returning quantified types from type functions is mighty fragile #219
Labels
bug
TC: Type Functions
Issues/PRs relating to top-level closed type functions
TC
Issues/PRs relating to something else in the TC
Comments
Also doesn't work: - | STrue -> y @unit ()
+ | STrue -> y () Error:
|
Also doesn't work: - | STrue -> y @unit ()
+ | STrue -> (y : forall 'a. 'a -> 'a) @unit () Error:
|
SquidDev
added
bug
TC
Issues/PRs relating to something else in the TC
TC: Type Functions
Issues/PRs relating to top-level closed type functions
labels
Nov 11, 2019
This rephrasing of the program works: let
foo :
forall 'b. sbool 'b -> foo 'b -> ()
=
function
| STrue -> fun (y : forall 'a. 'a -> 'a) -> y ()
| SFalse -> fun y -> y |
Possible solution here: |
Problem with the possible solution: Core has no dependent types lol |
What I am going to do is write a warning for this |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Labels
bug
TC: Type Functions
Issues/PRs relating to top-level closed type functions
TC
Issues/PRs relating to something else in the TC
It is reasonable to expect this would type check, but no.
The text was updated successfully, but these errors were encountered: