]> git.lyx.org Git - features.git/commitdiff
sanity check
authorAndré Pönitz <poenitz@gmx.net>
Tue, 2 Oct 2001 10:50:10 +0000 (10:50 +0000)
committerAndré Pönitz <poenitz@gmx.net>
Tue, 2 Oct 2001 10:50:10 +0000 (10:50 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@2832 a592a061-630c-0410-9148-cb99ea01b6c8

src/mathed/math_macrotemplate.C

index 09b6075f210dcb5e9313d40f0b0fc0ce31894a0d..79e1894e1bfa8c53a096a05c935bbb8d3dd582d1 100644 (file)
@@ -14,7 +14,12 @@ MathMacroTemplate::MathMacroTemplate()
 
 MathMacroTemplate::MathMacroTemplate(string const & nm, int numargs)
        : MathNestInset(1), numargs_(numargs), name_(nm)
-{}
+{
+       if (numargs_ < 1 || numargs_ > 9) {
+               lyxerr << "MathMacroTemplate::MathMacroTemplate: wrong # of arguments: "
+                       << numargs_ << std::endl;
+       }
+}
 
 
 MathInset * MathMacroTemplate::clone() const