clarified signature: explicit variable is easier to find in source;
authorwenzelm
Wed, 27 Mar 2024 12:54:43 +0100
changeset 80022 77e605c66797
parent 80021 ba06861e91f9
child 80023 c43a51fde4f5
clarified signature: explicit variable is easier to find in source;
src/Pure/System/setup_tool.scala
--- a/src/Pure/System/setup_tool.scala	Wed Mar 27 12:50:37 2024 +0100
+++ b/src/Pure/System/setup_tool.scala	Wed Mar 27 12:54:43 2024 +0100
@@ -15,11 +15,10 @@
     services.foreach(_.init(other_isabelle, verbose = verbose))
 }
 
-abstract class Setup_Tool(tool: String)
+abstract class Setup_Tool(tool: String, val variable: String)
 extends Isabelle_System.Service {
   override def toString: String = tool
 
-  val variable: String = "ISABELLE_" + Word.uppercase(tool)
   val files: List[Path] = List(Path.explode("lib/Tools") + Path.basic(tool))
 
   def test(other_isabelle: Other_Isabelle): Boolean =
@@ -33,5 +32,5 @@
     if (test(other_isabelle)) run(other_isabelle, verbose = verbose)
 }
 
-class GHC_Setup extends Setup_Tool("ghc_setup")
-class OCaml_Setup extends Setup_Tool("ocaml_setup")
+class GHC_Setup extends Setup_Tool("ghc_setup", "ISABELLE_GHC_SETUP")
+class OCaml_Setup extends Setup_Tool("ocaml_setup", "ISABELLE_OCAML_SETUP")