Skip to content

Instantly share code, notes, and snippets.

@tfausak
Last active October 30, 2015 03:20
Show Gist options
  • Save tfausak/b57727bfbc4987f8e1bc to your computer and use it in GitHub Desktop.
Save tfausak/b57727bfbc4987f8e1bc to your computer and use it in GitHub Desktop.
An excessively long PureScript error.
Error found:
in module Test.Main
at /Users/tfausak/Documents/GitHub/purescript-ax/test/Main.purs line 6, column 8 - line 135, column 1
Could not match expected type
( output :: OUTPUT
)
with actual type
()
while trying to match type ( output :: OUTPUT
, assert :: ASSERT
)
with type ( assert :: ASSERT
)
while checking that expression (bind (((==>) (((+) [ 1
]
)
[ 2
]
)
)
[ 1
, 2
]
)
)
(\__unused ->
(bind (((==>) (((+) 1) 2)) 3)) (\__unused ->
(bind (((==>) (((+) 1.0) 2.0)) 3.0)) (\__unused ->
(bind (((==>) (((+) "1") "2")) "12")) (\__unused ->
(bind (((==>) (((&&) true) true)) true)) (\__unused ->
(bind (((==>) ((((&&) (\_9 ->
case _9 of
_ -> true
)
)
(\_10 ->
case _10 of
_ -> true
)
)
unit
)
)
true
)
)
(\__unused ->
(bind (((==>) ((apply [ \_0 ->
((+) _0) 1
, \_1 ->
((+) _1) 2
]
)
[ 1
, 2
]
)
)
[ 2
, 3
, 3
, 4
]
)
)
(\__unused ->
(bind (((==>) (((apply (+)) (\_2 ->
((+) _2) 2
)
)
1
)
)
4
)
)
(\__unused ->
(bind (((==>) ((bind [ 1
, 2
]
)
(\x ->
[ x
, ((+) x) 1
]
)
)
)
[ 1
, 2
, 2
, 3
]
)
)
(\__unused ->
(bind (((==>) (((bind (\_3 ->
((+) _3) 2
)
)
(+)
)
1
)
)
4
)
)
(\__unused ->
(bind (((==>) bottom) false)) (\__unused ->
(bind (((==>) top) true)) (\__unused ->
(bind (((==>) bottom) (negate 2147483648))) (\__unused ->
(bind (((==>) top) 2147483647)) (\__unused ->
(bind (((==>) ((compare [ 1
]
)
[ 1
]
)
)
EqualTo
)
)
(\__unused ->
(bind (((==>) ((compare false) true)) LessThan)) (\__unused ->
(bind (((==>) ((compare 'b') 'a')) GreaterThan)) (\__unused ->
(bind (((==>) ((compare 1) 1)) EqualTo)) (\__unused ->
(bind (((==>) ((compare 0.1) 2.3)) LessThan)) (\__unused ->
(bind (((==>) ((compare EqualTo) LessThan)) GreaterThan)) (\__unused ->
(bind (((==>) ((compare "ax") "ax")) EqualTo)) (\__unused ->
(bind (((==>) ((((>>) (\_4 ->
((+) _4) 2
)
)
(\_5 ->
((*) _5) 2
)
)
3
)
)
10
)
)
(\__unused ->
(bind (((==>) (((/) 5) 2)) 2)) (\__unused ->
(bind (((==>) (((%) 5) 2)) 1)) (\__unused ->
(bind (((==>) (((/) 5.0) 2.0)) 2.5)) (\__unused ->
(bind (((==>) (((%) 5.0) 2.0)) 0.0)) (\__unused ->
(bind (((==>) (((==) [ 1
]
)
[ 1
]
)
)
true
)
)
(\__unused ->
(bind (((==>) (((==) true) false)) false)) (\__unused ->
(bind (((==>) (((==) 'a') 'a')) true)) (\__unused ->
(bind (((==>) (((==) 1) 2)) false)) (\__unused ->
(bind (((==>) (((==) 1.0) 1.0)) true)) (\__unused ->
(bind (((==>) (((==) { k: "a"
}
)
{ k: "z"
}
)
)
false
)
)
(\__unused ->
(bind (((==>) (((==) "ax") "ax")) true)) (\__unused ->
(bind (((==>) (identity unit)) unit)) (\__unused ->
(bind (((==>) ((map (\_6 ->
((+) _6) 1
)
)
[ 1
, 2
]
)
)
[ 2
, 3
]
)
)
(\__unused ->
(bind (((==>) (((map (\_7 ->
((+) _7) 2
)
)
(\_8 ->
((*) _8) 2
)
)
3
)
)
8
)
)
(\__unused ->
(bind (((==>) (((*) 2) 3)) 6)) (\__unused ->
(bind (((==>) (((*) 2.0) 3.0)) 6.0)) (\__unused ->
(bind (((==>) (not true)) false)) (\__unused ->
(bind (((==>) ((not (\_11 ->
case _11 of
_ -> false
)
)
unit
)
)
true
)
)
(\__unused ->
(bind (((==>) one) 1)) (\__unused ->
(bind (((==>) one) 1.0)) (\__unused ->
(bind (((==>) (((||) false) true)) true)) (\__unused ->
(bind (((==>) ((((||) (\_12 ->
case _12 of
_ -> true
)
)
(\_13 ->
case _13 of
_ -> false
)
)
unit
)
)
true
)
)
(\__unused ->
(bind (((==>) bottom) LessThan)) (\__unused ->
(bind (((==>) top) GreaterThan)) (\__unused ->
(bind (((==>) (((==) EqualTo) EqualTo)) true)) (\__unused ->
(bind (((==>) (show LessThan)) "LessThan")) (\__unused ->
(bind (((==>) (pure 1)) [ 1
]
)
)
(\__unused ->
(bind (((==>) (show [ 1
, 2
]
)
)
"[1, 2]"
)
)
(\__unused ->
(bind (((==>) (show true)) "true")) (\__unused ->
(bind (((==>) (show 'a')) "'a'")) (\__unused ->
(bind (((==>) (show 0)) "0")) (\__unused ->
(bind (((==>) (show 1.2)) "1.2")) (\__unused ->
(bind (((==>) (show "ax")) "\"ax\"")) (\__unused ->
(bind (((==>) (((-) 2) 3)) (negate 1))) (\__unused ->
(bind (((==>) (((-) 3.0) 2.0)) 1.0)) (\__unused ->
(bind (((==>) (((+) unit) unit)) unit)) (\__unused ->
(bind (((==>) (((&&) unit) unit)) unit)) (\__unused ->
(bind (((==>) bottom) unit)) (\__unused ->
(bind (((==>) top) unit)) (\__unused ->
(bind (((==>) ((compare unit) unit)) EqualTo)) (\__unused ->
(bind (((==>) ((divide unit) unit)) unit)) (\__unused ->
(bind (((==>) ((modulo unit) unit)) unit)) (\__unused ->
(bind (((==>) (((*) unit) unit)) unit)) (\__unused ->
(bind (((==>) (not unit)) unit)) (\__unused ->
(bind (((==>) one) unit)) (\__unused ->
(bind (((==>) (((||) unit) unit)) unit)) (\__unused ->
(bind (((==>) (show unit)) "unit")) (\__unused ->
(bind (((==>) (((-) unit) unit)) unit)) (\__unused ->
(bind (((==>) zero) unit)) (\__unused ->
(bind (((==>) zero) [])) (\__unused ->
(bind (((==>) zero) 0)) (\__unused ->
(bind (((==>) zero) 0.0)) (\__unused ->
(bind (((==>) zero) "")) (\__unused ->
pure unit
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
)
has type Effect ( assert :: ASSERT
)
Unit
in value declaration main
See https://github.com/purescript/purescript/wiki/Error-Code-TypesDoNotUnify for more information,
or to contribute content related to this error.
Compiling Test.Main
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment