File tree Expand file tree Collapse file tree 5 files changed +27
-2
lines changed
sbt-dotty/sbt-test/sbt-dotty/compiler-plugin
appOK/src/main/scala/hello Expand file tree Collapse file tree 5 files changed +27
-2
lines changed Original file line number Diff line number Diff line change 1+ package hello
2+
3+ object Hello {
4+ def main (args : Array [String ]): Unit = {
5+ val dotty : Int | String = " dotty"
6+ println(s " Hello $dotty! " )
7+ }
8+ }
Original file line number Diff line number Diff line change @@ -22,3 +22,9 @@ lazy val app = project
2222 .settings(
2323 scalaVersion := dottyVersion
2424 )
25+
26+ lazy val appOk = project
27+ .in(file(" appOk" ))
28+ .settings(
29+ scalaVersion := dottyVersion
30+ )
Original file line number Diff line number Diff line change @@ -19,3 +19,10 @@ lazy val app = project
1919 scalaVersion := dottyVersion,
2020 addCompilerPlugin(" ch.epfl.lamp" %% " dividezero" % " 0.0.1" )
2121 )
22+
23+ lazy val appOk = project
24+ .in(file(" appOk" ))
25+ .settings(
26+ scalaVersion := dottyVersion,
27+ addCompilerPlugin(" ch.epfl.lamp" %% " dividezero" % " 0.0.1" )
28+ )
Original file line number Diff line number Diff line change @@ -19,8 +19,8 @@ class DivideZero extends PluginPhase with StandardPlugin {
1919
2020 val phaseName = name
2121
22- override val runsAfter = Set (Pickler .name)
23- override val runsBefore = Set (Staging .name)
22+ override val runsAfter = Set (Staging .name)
23+ override val runsBefore = Set (Pickler .name)
2424
2525 def init (options : List [String ]): List [PluginPhase ] = this :: Nil
2626
Original file line number Diff line number Diff line change 88$ copy-file changes/build.sbt build.sbt
99> reload
1010
11+ # Should compile with the plugin
12+ > clean
13+ > appOk/compile
14+
1115# Should NOT compile with the plugin
1216> clean
1317-> app/compile
You can’t perform that action at this time.
0 commit comments