We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hello. I found the following simple code doesn't type check with Idris v1.3.0:
test3 : Integer test3 = let (x,y) = (1,2) in x+y
The error message says about linear types, and it is I think unexpected.
module Main test3 : Integer test3 = let (x,y) = (1,2) in x+y main : IO () main = pure ()
idris Main.idr -o main
Compiled successfully.
Main.idr:4:13-17: | 4 | test3 = let (x,y) = (1,2) in x+y | ~~~~~ Trying to use linear name x in non-linear context
The text was updated successfully, but these errors were encountered:
Same here. Idris 1.3.1
Code:
screenScale : Double screenScale = 33 resolution : (Int, Int) resolution = (1280, 960) Cast (Int, Int) (Double, Double) where cast (x, y) = (cast x, cast y) positionToScreen : (camera : Vector2D) -> (position : Vector2D) -> (Int, Int) positionToScreen (cx, cy) (ox, oy) = let (x, y) = screenScale `scale` (ox - cx, oy - cy) (asdf1, asdf2) = the (Double, Double) (cast resolution) in -- ERROR HERE cast (x - asdf1/2, y - asdf2/2)
Error message: Trying to use linear name asdf1 in non-linear context
Trying to use linear name asdf1 in non-linear context
Sorry, something went wrong.
No branches or pull requests
Hello.
I found the following simple code doesn't type check with Idris v1.3.0:
The error message says about linear types, and it is I think unexpected.
Steps to Reproduce
Main.idr
Expected Behavior
Compiled successfully.
Observed Behavior
The text was updated successfully, but these errors were encountered: