elm-lang / elm-repl

A REPL for Elm
BSD 3-Clause "New" or "Revised" License
170 stars 34 forks source link

1 + 1 : Array error!? #150

Closed kristianmandrup closed 7 years ago

kristianmandrup commented 7 years ago

Why doesn't 1 + 1 work in Elm 0.18 !?

 $ elm-repl
---- elm-repl 0.18.0 -----------------------------------------------------------
 :help for help, :exit to exit, more at <https://github.com/elm-lang/elm-repl>
--------------------------------------------------------------------------------
> 1 + 1
-- SYNTAX PROBLEM --------- elm-stuff/packages/elm-lang/core/3.0.0/src/Array.elm

I ran into something unexpected when parsing your code!

2|     ( Array
       ^
I am looking for one of the following things:

    something like `exposing (..)` which replaced `where` in 0.17
    whitespace

Same goes for ++

> "a" ++ "b"
-- SYNTAX PROBLEM --------- elm-stuff/packages/elm-lang/core/3.0.0/src/Array.elm

I ran into something unexpected when parsing your code!

2|     ( Array
       ^
I am looking for one of the following things:

    something like `exposing (..)` which replaced `where` in 0.17
    whitespace

Looks like whatever I type results in this error. So I must expose something first for my program to work!?

process-bot commented 7 years ago

Thanks for the issue! Make sure it satisfies this checklist. My human colleagues will appreciate it!

Here is what to expect next, and if anyone wants to comment, keep these things in mind.

kristianmandrup commented 7 years ago

Turns out it was due to elm-repl being launched from ~ (USER HOME). When I rebooted and relaunched from a place like repos/elm-projs it worked :) Very strange though!