From 752bb110d0d454a0ade0ccbe0f551fca7c2cf0ee Mon Sep 17 00:00:00 2001 From: Simon Parten Date: Sat, 26 Oct 2024 18:07:01 +0200 Subject: [PATCH] remove internal validations --- cli/src/org/scalajs/cli/Scalajsld.scala | 19 +------------------ 1 file changed, 1 insertion(+), 18 deletions(-) diff --git a/cli/src/org/scalajs/cli/Scalajsld.scala b/cli/src/org/scalajs/cli/Scalajsld.scala index e288f4a..937588d 100644 --- a/cli/src/org/scalajs/cli/Scalajsld.scala +++ b/cli/src/org/scalajs/cli/Scalajsld.scala @@ -282,24 +282,7 @@ object Scalajsld { } } - val wasEsModule = c.emitWasm match { - case true => - if (c.moduleKind != ModuleKind.ESModule) { - failure("Wasm can only be emitted with module kind EsModule") - } else success - case false => success - } - - val wasmFewestModules = c.emitWasm match { - case true => { - if (c.moduleSplitStyle != ModuleSplitStyle.FewestModules.toString) { - failure("Wasm can only be emitted with module split style FewestModules") - } else success - } - case false => success - } - - val allValidations = Seq(outputCheck, importMapCheck, wasEsModule, wasmFewestModules) + val allValidations = Seq(outputCheck, importMapCheck) allValidations.forall(_.isRight) match { case true => success case false => failure(allValidations.filter(_.isLeft).map(_.left.get).mkString("\n\n"))