mirror of
https://github.com/idris-lang/Idris2.git
synced 2024-12-19 09:12:34 +03:00
23 lines
589 B
Plaintext
23 lines
589 B
Plaintext
1/1: Building Test (Test.idr)
|
|
Error: No unrestricted arguments of type `Integer` found for natToMyNat.
|
|
|
|
Test:20:1--20:37
|
|
16 | natToMyNat : Nat -> MyNat
|
|
17 | natToMyNat Z = Z
|
|
18 | natToMyNat (S k) = S $ natToMyNat k
|
|
19 |
|
|
20 | %builtin IntegerToNatural natToMyNat
|
|
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
Error: Return type is not a 'Nat'-like type
|
|
|
|
Test:25:1--25:42
|
|
21 |
|
|
22 | integerToNotNat : Integer -> Maybe String
|
|
23 | integerToNotNat x = Just "Boo"
|
|
24 |
|
|
25 | %builtin IntegerToNatural integerToNotNat
|
|
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
Main> Bye for now!
|