aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIan Hinder <ian.hinder@aei.mpg.de>2013-09-12 16:33:43 +0200
committerIan Hinder <ian.hinder@aei.mpg.de>2013-09-12 16:33:43 +0200
commit311d24d35eab704df7153748d0f4f205eb1c081b (patch)
tree403060404a14e6c99be0c6a8855520685970f8fe
parenteb39bfe8446e1a5a9adbc4977062ab0a6e40c5f2 (diff)
KrancThorn.m: Eliminate several temporary variables
-rw-r--r--Tools/CodeGen/KrancThorn.m29
1 files changed, 16 insertions, 13 deletions
diff --git a/Tools/CodeGen/KrancThorn.m b/Tools/CodeGen/KrancThorn.m
index 222f98a..c1966ef 100644
--- a/Tools/CodeGen/KrancThorn.m
+++ b/Tools/CodeGen/KrancThorn.m
@@ -68,10 +68,10 @@ CreateKrancThorn[groupsOrig_, parentDirectory_, thornName_, opts:OptionsPattern[
parameters,
configuration,
partialDerivs, evolvedGroups, rhsGroups, nonevolvedGroups,
- interface, evolvedGroupDefinitions, thornspec,
+ interface, evolvedGroupDefinitions,
evolvedODEGroups, nonevolvedODEGroups,
evolvedODEGroupDefinitions, rhsODEGroups,
- consCalcs, consCalcsIn, consGroups, cakernel,
+ cakernel,
sources = {}},
InfoMessage[Terse, "Processing arguments to CreateKrancThorn"];
@@ -406,17 +406,20 @@ CreateKrancThorn[groupsOrig_, parentDirectory_, thornName_, opts:OptionsPattern[
------------------------------------------------------------------------ *)
(* Put all the above together and generate the Cactus thorn *)
- thornspec = {Name -> thornName,
- Directory -> parentDirectory,
- Configuration -> configuration,
- Interface -> interface,
- Schedule -> schedule,
- Param -> param,
- CaKernel -> cakernel,
- Makefile -> make,
- Sources -> sources};
- InfoMessage[Terse, "Creating thorn"];
- CreateThorn[thornspec]];
+
+ Module[
+ {thornspec},
+ thornspec = {Name -> thornName,
+ Directory -> parentDirectory,
+ Configuration -> configuration,
+ Interface -> interface,
+ Schedule -> schedule,
+ Param -> param,
+ CaKernel -> cakernel,
+ Makefile -> make,
+ Sources -> sources};
+ InfoMessage[Terse, "Creating thorn"];
+ CreateThorn[thornspec]]];
End[];
EndPackage[];