@@ -214,6 +214,30 @@ class CompilationTests extends ParallelTesting {
214
214
compileDir(" ../library/src" ,
215
215
allowDeepSubtypes.and(" -Ycheck-reentrant" , " -strict" , " -priorityclasspath" , defaultOutputDir))
216
216
217
+ def sources (paths : JStream [Path ], excludedFiles : List [String ] = Nil ): List [String ] =
218
+ paths.iterator().asScala
219
+ .filter(path =>
220
+ (path.toString.endsWith(" .scala" ) || path.toString.endsWith(" .java" ))
221
+ && ! excludedFiles.contains(path.getFileName.toString))
222
+ .map(_.toString).toList
223
+
224
+ val compilerDir = Paths .get(" ../compiler/src" )
225
+ val compilerSources = sources(Files .walk(compilerDir))
226
+
227
+ val backendDir = Paths .get(" ../scala-backend/src/compiler/scala/tools/nsc/backend" )
228
+ val backendJvmDir = Paths .get(" ../scala-backend/src/compiler/scala/tools/nsc/backend/jvm" )
229
+
230
+ // NOTE: Keep these exclusions synchronized with the ones in the sbt build (Build.scala)
231
+ val backendExcluded =
232
+ List (" JavaPlatform.scala" , " Platform.scala" , " ScalaPrimitives.scala" )
233
+ val backendJvmExcluded =
234
+ List (" BCodeICodeCommon.scala" , " GenASM.scala" , " GenBCode.scala" , " ScalacBackendInterface.scala" , " BackendStats.scala" , " BCodeAsmEncode.scala" )
235
+
236
+ val backendSources =
237
+ sources(Files .list(backendDir), excludedFiles = backendExcluded)
238
+ val backendJvmSources =
239
+ sources(Files .list(backendJvmDir), excludedFiles = backendJvmExcluded)
240
+
217
241
def dotty1 = {
218
242
compileList(
219
243
" dotty1" ,
@@ -349,7 +373,7 @@ class CompilationTests extends ParallelTesting {
349
373
val backendExcluded =
350
374
List (" JavaPlatform.scala" , " Platform.scala" , " ScalaPrimitives.scala" )
351
375
val backendJvmExcluded =
352
- List (" BCodeICodeCommon.scala" , " GenASM.scala" , " GenBCode.scala" , " ScalacBackendInterface.scala" )
376
+ List (" BCodeICodeCommon.scala" , " GenASM.scala" , " GenBCode.scala" , " ScalacBackendInterface.scala" , " BackendStats.scala " )
353
377
354
378
val backendSources0 =
355
379
sources(Files .list(backendDir), excludedFiles = backendExcluded)
0 commit comments