Created
March 5, 2016 14:18
-
-
Save tgecho/97d8ddcbab7fe66d3ee7 to your computer and use it in GitHub Desktop.
Elm whitespace confusion
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
viewCounter address ( id, model ) = | |
let context = | |
Counter.Context | |
(Signal.forwardTo address (Modify id)) | |
(Signal.forwardTo address (always (Remove id))) | |
in | |
Counter.viewWithRemoveButton context model | |
{- | |
==== error in Bad.elm:4:8: ==== | |
I ran into something unexpected when parsing your code! | |
I am looking for one of the following things: | |
whitespace | |
---- | |
-} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
I'm a little confused about the whitespace rules that lead to Bad.elm failing. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
viewCounter1 address ( id, model ) = | |
let | |
context = | |
Counter.Context | |
(Signal.forwardTo address (Modify id)) | |
(Signal.forwardTo address (always (Remove id))) | |
in | |
Counter.viewWithRemoveButton context model | |
viewCounter2 address ( id, model ) = | |
let context = | |
Counter.Context | |
(Signal.forwardTo address (Modify id)) | |
(Signal.forwardTo address (always (Remove id))) | |
in | |
Counter.viewWithRemoveButton context model | |
viewCounter3 address ( id, model ) = | |
let context = | |
Counter.Context | |
(Signal.forwardTo address (Modify id)) | |
(Signal.forwardTo address (always (Remove id))) | |
in | |
Counter.viewWithRemoveButton context model |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment