aboutsummaryrefslogtreecommitdiff
path: root/Tools/CodeGen
diff options
context:
space:
mode:
authorIan Hinder <ian.hinder@aei.mpg.de>2010-09-29 00:55:52 +0100
committerIan Hinder <ian.hinder@aei.mpg.de>2010-09-29 00:55:52 +0100
commit5713f44742a1ce14c9d13f981827be3be6f7e8b8 (patch)
tree9e9fce072bf02f10b1e049f8b4bf4a40e907b11e /Tools/CodeGen
parent2417f7def1e90a9b43ab2623c971a74342d7ef41 (diff)
Differencing.m: Throw an error if the FD operator definition does not match the pattern
Previously Kranc silently generated nonsense code
Diffstat (limited to 'Tools/CodeGen')
-rw-r--r--Tools/CodeGen/Differencing.m3
1 files changed, 2 insertions, 1 deletions
diff --git a/Tools/CodeGen/Differencing.m b/Tools/CodeGen/Differencing.m
index 32c5ddb..0eb864e 100644
--- a/Tools/CodeGen/Differencing.m
+++ b/Tools/CodeGen/Differencing.m
@@ -308,7 +308,8 @@ ComponentDerivativeOperatorMacroDefinition[componentDerivOp:(name_[inds___] -> e
(* Print["liName == ", liName];*)
rhs3 = rhs2 /. pat -> Times[liName, rest],
-(* Print["!!!!!!!!DOES NOT MATCH!!!!!!!!!"];*)
+ ThrowError["Partial derivative operator definition ", rhs2,
+ " does not match pattern ", pat];
rhs3 = rhs2];
(* Print["rhs3 == ", rhs3];*)