Skip to content
New issue

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

More limits of text-based REPL #9016

Closed
scabug opened this issue Nov 29, 2014 · 2 comments
Closed

More limits of text-based REPL #9016

scabug opened this issue Nov 29, 2014 · 2 comments
Labels

Comments

@scabug
Copy link

scabug commented Nov 29, 2014

This one got by Paul's pet monkey:

Welcome to Scala version 2.11.4 (Java HotSpot(TM) 64-Bit Server VM, Java 1.8.0_11).
Type in expressions to have them evaluated.
Type :help for more information.

scala> .1
<console>:1: error: ';' expected but double literal found.
       $intp.1
            ^
@scabug
Copy link
Author

scabug commented Nov 29, 2014

Imported From: https://issues.scala-lang.org/browse/SI-9016?orig=1
Reporter: @som-snytt
Affected Versions: 2.11.4

@scabug
Copy link
Author

scabug commented Mar 22, 2017

@som-snytt said:

$ scala
Welcome to Scala 2.12.1 (OpenJDK 64-Bit Server VM, Java 1.8.0_112).
Type in expressions for evaluation. Or try :help.

scala> :pa
// Entering paste mode (ctrl-D to finish)

val right1: Right[Double, Int] = Right(1)
val right2                     = Right(2)
val right3                     = Right(3)
val left23: Left[Double, Int]  = Left(23.0)
val left42                     = Left(42.0)

for {
  a <- right1
  b <- right2
  c <- right3
} yield a + b + c // Right(6)

// Exiting paste mode, now interpreting.

<console>:8: error: illegal start of simple pattern
;
^
<console>:9: warning: val keyword in for comprehension is deprecated
val res0 =
         ^
<console>:10: error: '}' expected but '<-' found.
  a <- right1
    ^
<console>:11: error: ';' expected but '<-' found.
  b <- right2
    ^
<console>:12: error: ';' expected but '<-' found.
  c <- right3
    ^
<console>:13: error: eof expected but '}' found.
} yield a + b + c // Right(6)
^

scala> 

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant