mirror of
https://github.com/idris-lang/Idris2.git
synced 2024-12-26 13:11:30 +03:00
13ef8ba707
I can't make sense of this code, it seems to try to convert the case function corresponding to `let (a, b) = f n in ...` into a different case function where `f n` and `(a, b)` have been unified. But if `f n` is a bona fide stuck computation, there's no chance of this happening. Just turning this off solves the #1782 and only breaks one function in the whole of the idris2 repo (I would have expected our current termination oracle to be too weak to detect it as valid anyway!) and one in frex (which, again, should not have been seen as terminating). Also fixes #1460
12 lines
227 B
Idris
12 lines
227 B
Idris
total
|
|
notHack : Nat -> (Nat, Nat)
|
|
notHack Z = (Z, Z)
|
|
notHack (S n) = let (baz1, baz2) = notHack n
|
|
in (baz2, S baz1)
|
|
|
|
|
|
total
|
|
hack : Nat -> (Void, Void)
|
|
hack n = let (baz1, baz2) = hack n
|
|
in (baz1, baz2)
|