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
Scala code runner version 3.2.0-RC1-bin-SNAPSHOT-git-8600c3d -- Copyright 2002-2022, LAMP/EPFL
def f(b: Boolean) = if b then 42 else 17 + 27 def g(b: Boolean) = if b then 42 else 17 end if + 27
Similar example from the convo:
def f = for res <- List(1, 2) yield if res == 1 then "one!" else "two!" end if + "end"
def f(b: Boolean): Int = if b then 42 else 17.+(27) def g(b: Boolean): Int = { if b then 42 else 17 27.unary_+ }
or
def f: List[String] = List.apply[Int]([1,2 : Int]*).map[String]( { def $anonfun(res: Int): String = (if res.==(1) then "one!" else "two!").+("end") closure($anonfun) } )
General expectation is that end markers merely document indentation regions.
If an end marker alters parsing, I expect a warning or error.
Also, I expect minimal feelings of confusion. Like a joke, if you have to explain it, it's no longer funny.
Noticed at https://discord.com/channels/632150470000902164/632628644035952680/967050718450155590
The text was updated successfully, but these errors were encountered:
val
No branches or pull requests
Compiler version
Scala code runner version 3.2.0-RC1-bin-SNAPSHOT-git-8600c3d -- Copyright 2002-2022, LAMP/EPFL
Minimized code
Similar example from the convo:
Output
or
Expectation
General expectation is that end markers merely document indentation regions.
If an end marker alters parsing, I expect a warning or error.
Also, I expect minimal feelings of confusion. Like a joke, if you have to explain it, it's no longer funny.
Noticed at https://discord.com/channels/632150470000902164/632628644035952680/967050718450155590
The text was updated successfully, but these errors were encountered: