Skip to content

Commit 873df82

Browse files
authored
Merge pull request #492 from MaximeKjaer/fix-instanceofs-1.x
Fix instanceOfs linker config for Scala.js 1.x
2 parents 87e6a60 + 8341ca9 commit 873df82

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

doc/semantics.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -145,6 +145,11 @@ JVM semantics, you can do so with an sbt setting.
145145
For example, this setting enables compliant `asInstanceOf`s:
146146

147147
{% highlight scala %}
148+
// Scala.js 1.x
149+
scalaJSLinkerConfig ~= { _.withSemantics(_.withAsInstanceOfs(
150+
org.scalajs.linker.interface.CheckedBehavior.Compliant)) }
151+
152+
// Scala.js 0.6.x
148153
scalaJSLinkerConfig ~= { _.withSemantics(_.withAsInstanceOfs(
149154
org.scalajs.core.tools.sem.CheckedBehavior.Compliant)) }
150155
{% endhighlight %}

0 commit comments

Comments
 (0)