Skip to content

Instantly share code, notes, and snippets.

@neshkeev
Created September 19, 2019 03:38
Show Gist options
  • Save neshkeev/86d7a3b624418c3cd6b149c0ff9c23ae to your computer and use it in GitHub Desktop.
Save neshkeev/86d7a3b624418c3cd6b149c0ff9c23ae to your computer and use it in GitHub Desktop.
[info] Loading settings for project dotty-build-build from build.sbt ...
[info] Loading project definition from /home/me/dotty/project/project
[info] Loading settings for project dotty-build from plugins.sbt,build.sbt ...
[info] Loading project definition from /home/me/dotty/project
[info] Compiling 1 Scala source to /home/me/dotty/project/target/scala-2.12/sbt-1.0/classes ...
[info] Done compiling.
[info] Loading settings for project dotty from build.sbt ...
[info] Resolving key references (15722 settings) ...
[info] Set current project to dotty (in build file:/home/me/dotty/)
[info] Checking out Scala.js source version 1.0.0-M8
[warn] Multiple main classes detected. Run 'show discoveredMainClasses' to see the list
[info] Compiling 1 Scala source to /home/me/dotty/tests/sjs-junit/../out/bootstrap/sjsJUnitTests/scala-0.19/test-classes ...
[error] -- [E018] Syntax Error: /home/me/dotty/tests/sjs-junit/../out/bootstrap/sjsJUnitTests/scala-js-src-1.0.0-M8/test-suite/shared/src/test/scala/org/scalajs/testsuite/javalib/lang/StringTest.scala:258:55
[error] 258 | assertArrayEquals(Array[AnyRef]("Sc", "l", ".js"), erased("Scala.js".split("a")))
[error] | ^^^^^^
[error] | expression expected but erased found
[error] -- [E018] Syntax Error: /home/me/dotty/tests/sjs-junit/../out/bootstrap/sjsJUnitTests/scala-js-src-1.0.0-M8/test-suite/shared/src/test/scala/org/scalajs/testsuite/javalib/lang/StringTest.scala:260:59
[error] 260 | assertArrayEquals(Array[AnyRef]("a", "s", "d", "f"), erased("asdf".split("")))
[error] | ^^^^^^
[error] | expression expected but erased found
[error] -- [E018] Syntax Error: /home/me/dotty/tests/sjs-junit/../out/bootstrap/sjsJUnitTests/scala-js-src-1.0.0-M8/test-suite/shared/src/test/scala/org/scalajs/testsuite/javalib/lang/StringTest.scala:261:63
[error] 261 | assertArrayEquals(Array[AnyRef]("a", "s", "d", "f", ""), erased("asdf".split("", -1)))
[error] | ^^^^^^
[error] | expression expected but erased found
[error] -- [E018] Syntax Error: /home/me/dotty/tests/sjs-junit/../out/bootstrap/sjsJUnitTests/scala-js-src-1.0.0-M8/test-suite/shared/src/test/scala/org/scalajs/testsuite/javalib/lang/StringTest.scala:266:51
[error] 266 | assertArrayEquals(Array[AnyRef]("Scala","js"), erased("Scala.js".split('.')))
[error] | ^^^^^^
[error] | expression expected but erased found
[error] -- [E018] Syntax Error: /home/me/dotty/tests/sjs-junit/../out/bootstrap/sjsJUnitTests/scala-js-src-1.0.0-M8/test-suite/shared/src/test/scala/org/scalajs/testsuite/javalib/lang/StringTest.scala:269:70
[error] 269 | assertArrayEquals(Array[AnyRef]("blah", "blah", "blah", "blah"),
[error] | ^
[error] | expression expected but erased found
[error] -- [E040] Syntax Error: /home/me/dotty/tests/sjs-junit/../out/bootstrap/sjsJUnitTests/scala-js-src-1.0.0-M8/test-suite/shared/src/test/scala/org/scalajs/testsuite/javalib/lang/StringTest.scala:441:22
[error] 441 | @inline private def erased(array: Array[String]): Array[AnyRef] = {
[error] | ^^^^^^
[error] | an identifier expected, but 'erased' found
[error] 6 errors found
[error] (sjsJUnitTests / Test / compileIncremental) Compilation failed
[error] Total time: 7 s, completed Sep 19, 2019, 6:43:59 AM
@Lacaranian
Copy link

The tests define a function with a name of erased, which conflict with the erased reserved keyword in Dotty. One possible fix is lampepfl/dotty-feature-requests#71

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment