changeset 216:e83d64b26659

[project @ 1993-11-13 09:04:18 by jwe]
author jwe
date Sat, 13 Nov 1993 09:11:10 +0000
parents cf3f13026ff6
children cd2e49fb4f6b
files src/colloc.cc src/dassl.cc src/det.cc src/fsolve.cc src/fsqp.cc src/lex.l src/lpsolve.cc src/quad.cc src/rand.cc
diffstat 9 files changed, 23 insertions(+), 23 deletions(-) [+]
line wrap: on
line diff
--- a/src/colloc.cc	Sat Nov 13 08:41:22 1993 +0000
+++ b/src/colloc.cc	Sat Nov 13 09:11:10 1993 +0000
@@ -48,14 +48,14 @@
   if (args[1].const_type () != tree_constant_rep::complex_scalar_constant
       && args[1].const_type () != tree_constant_rep::scalar_constant)
     {
-      message ("colloc", "first argument must be a scalar");
+      error ("colloc: first argument must be a scalar");
       return retval;
     }
 
   int ncol = NINT (args[1].double_value ());
   if (ncol < 0)
     {
-      message ("colloc", "first argument must be non-negative");
+      error ("colloc: first argument must be non-negative");
       return retval;
     }
 
@@ -69,7 +69,7 @@
 	{
 	  if (! args[i].is_string_type ())
 	    {
-	      message ("colloc", "expecting string argument");
+	      error ("colloc: expecting string argument");
 	      return retval;
 	    }
 
@@ -88,20 +88,23 @@
 	    }
 	  else
 	    {
-	      message ("colloc", "unrecognized argument");
+	      error ("colloc: unrecognized argument");
 	      return retval;
 	    }
 	}
       else
 	{
-	  message ("colloc", "unexpected NULL argument");
+	  error ("colloc: unexpected NULL argument");
 	  return retval;
 	}
     }
 
   ntot += left + right;
   if (ntot < 1)
-    message ("colloc", "the total number of roots must be positive");
+    {
+      error ("colloc: the total number of roots must be positive");
+      return retval;
+    }
   
   CollocWt wts (ncol, left, right);
 
--- a/src/dassl.cc	Sat Nov 13 08:41:22 1993 +0000
+++ b/src/dassl.cc	Sat Nov 13 09:11:10 1993 +0000
@@ -128,7 +128,7 @@
 
   if (state.capacity () != deriv.capacity ())
     {
-      message ("dassl", "x and xdot must have the same size");
+      error ("dassl: x and xdot must have the same size");
       return retval;
     }
 
--- a/src/det.cc	Sat Nov 13 08:41:22 1993 +0000
+++ b/src/det.cc	Sat Nov 13 09:11:10 1993 +0000
@@ -75,9 +75,8 @@
 	    double rcond = 0.0;
 	    DET det = m.determinant (info, rcond);
 	    if (info == -1)
-	      message ("det",
-		       "matrix singular to machine precision, rcond = %g",
-		       rcond);
+	      error ("det: matrix singular to machine precision, rcond = %g",
+		     rcond);
 	    else
 	      {
 		double d = det.value ();
@@ -97,9 +96,8 @@
 	    double rcond = 0.0;
 	    ComplexDET det = m.determinant (info, rcond);
 	    if (info == -1)
-	      message ("det",
-		       "matrix singular to machine precision, rcond = %g",
-		       rcond);
+	      error ("det: matrix singular to machine precision, rcond = %g",
+		     rcond);
 	    else
 	      {
 		Complex c = det.value ();
--- a/src/fsolve.cc	Sat Nov 13 08:41:22 1993 +0000
+++ b/src/fsolve.cc	Sat Nov 13 09:11:10 1993 +0000
@@ -131,10 +131,10 @@
   ColumnVector x = args[2].to_vector ();
 
   if (nargin > 3)
-    message ("fsolve", "ignoring optional arguments...");
+    warning ("fsolve: ignoring optional arguments");
 
   if (nargout > 2)
-    message ("fsolve", "can't compute path output yet...");
+    warning ("fsolve: can't compute path output yet");
 
   NLFunc foo_fcn (fsolve_user_function);
   NLEqn foo (x, foo_fcn);
--- a/src/fsqp.cc	Sat Nov 13 08:41:22 1993 +0000
+++ b/src/fsqp.cc	Sat Nov 13 09:11:10 1993 +0000
@@ -79,7 +79,7 @@
 // Assumes that we have been given the correct number of arguments.
 
   tree_constant *retval = NULL_TREE_CONST;
-  message ("fsqp", "not implemented yet...");
+  error ("fsqp: not implemented yet");
   return retval;
 }
 
--- a/src/lex.l	Sat Nov 13 08:41:22 1993 +0000
+++ b/src/lex.l	Sat Nov 13 09:11:10 1993 +0000
@@ -1078,8 +1078,7 @@
 
       if (len > max_len)
 	{
-	  message ("grab_help_text",
-		   "buffer overflow after caching %d characters",
+	  warning ("grab_help_text: buffer overflow after caching %d chars",
 		   max_len);
 
 	  goto done;
--- a/src/lpsolve.cc	Sat Nov 13 08:41:22 1993 +0000
+++ b/src/lpsolve.cc	Sat Nov 13 09:11:10 1993 +0000
@@ -45,7 +45,7 @@
 // Assumes that we have been given the correct number of arguments.
 
   tree_constant *retval = NULL_TREE_CONST;
-  message ("lpsolve", "sorry, not implemented yet");
+  error ("lpsolve: not implemented yet");
   return retval;
 }
 
--- a/src/quad.cc	Sat Nov 13 08:41:22 1993 +0000
+++ b/src/quad.cc	Sat Nov 13 09:11:10 1993 +0000
@@ -126,7 +126,7 @@
     case 6:
       if (indefinite)
 	{
-	  message ("quad", "sorry, singularities not allowed on infinite intervals");
+	  error("quad: singularities not allowed on infinite intervals");
 	  return retval;
 	}
       have_sing = 1;
@@ -141,7 +141,7 @@
 	  abstol = tol.elem (0);
 	  break;
 	default:
-	  message ("quad", "expecting tol to contain no more than two values");
+	  error ("quad: expecting tol to contain no more than two values");
 	  return retval;
 	}
     case 4:
--- a/src/rand.cc	Sat Nov 13 08:41:22 1993 +0000
+++ b/src/rand.cc	Sat Nov 13 09:11:10 1993 +0000
@@ -168,7 +168,7 @@
 	    {
 	      delete [] retval;
 	      retval = NULL_TREE_CONST;
-	      message ("rand", "unrecognized string argument");
+	      error ("rand: unrecognized string argument");
 	    }
 	  break;
 	case tree_constant_rep::scalar_constant:
@@ -248,7 +248,7 @@
       retval[0] = tree_constant (rand_mat);
     }
   else
-    message ("rand", "invalid negative argument");
+    error ("rand: invalid negative argument");
 
   return retval;
 }