Better HN
top
new
best
ask
show
jobs
Log in
Sign up
Better HN
Comment
by
lower
· 5y ago · 0 comments
With x1 = Just, the program is accepted instantly by ghc. I think you need a type variable to appear twice.
Comments
[–]
NieDzejkob
5y ago
Ah, it's still exponential, but in the size of the type, and the constants of the complexity are a bit different, so you need around x30.
[–]
lower
OP
5y ago
Ah, you're right. If one goes to x_{i+1}, then there will be 2^i Maybes in the type. The number of Maybe-occurrences in the type doubles in each step and sharing won't help there.