scala-js/scala-js — pull request #45 by lihaoyi (2013-12-05 16:06:19+00:00)
Title: Fix #36: Comparing scala.String and js.String raises false warning

Makes `js.String` a type alias for `java.lang.String`. Since almost all of the cleverness of `js.String` was already handled by the compiler, this requires almost no changes inside ScalaJS itself. Verified that it passes the test suite, and runs my game (http://lihaoyi.github.io/scala-js-game-2/) perfectly fine.

We may want to do the same for other js.* types in future (`Double` -> `js.Number`, 'FunctionN` -> `js.FunctionN`, in order to avoid the same pattern-matching weirdness when the types are not exactly identical, but those would take some work to special case in the compiler.