=================================================================== RCS file: /home/cvs/OpenXM_contrib2/asir2000/engine/nd.c,v retrieving revision 1.86 retrieving revision 1.88 diff -u -p -r1.86 -r1.88 --- OpenXM_contrib2/asir2000/engine/nd.c 2003/10/28 08:47:01 1.86 +++ OpenXM_contrib2/asir2000/engine/nd.c 2003/12/24 02:20:19 1.88 @@ -1,8 +1,9 @@ -/* $OpenXM: OpenXM_contrib2/asir2000/engine/nd.c,v 1.85 2003/10/28 03:23:40 noro Exp $ */ +/* $OpenXM: OpenXM_contrib2/asir2000/engine/nd.c,v 1.87 2003/11/05 08:02:45 noro Exp $ */ #include "ca.h" #include "parse.h" #include "ox.h" +#include "base.h" #include "inline.h" #include @@ -117,7 +118,11 @@ typedef struct oIndArray int (*ndl_compare_function)(UINT *a1,UINT *a2); static int ndv_alloc; +#if 1 static int nd_f4_nsp=0x7fffffff; +#else +static int nd_f4_nsp=50; +#endif static double nd_scale=2; static UINT **nd_bound; static struct order_spec *nd_ord; @@ -2401,6 +2406,14 @@ void nd_gr(LIST f,LIST v,int m,int f4,struct order_spe ndv_alloc = 0; get_vars((Obj)f,&fv); pltovl(v,&vv); for ( nvar = 0, tv = vv; tv; tv = NEXT(tv), nvar++ ); + switch ( ord->id ) { + case 1: + if ( ord->nv != nvar ) + error("nd_{gr,f4} : invalid order specification"); + break; + default: + break; + } nd_init_ord(ord); for ( t = BDY(f), max = 0; t; t = NEXT(t) ) for ( tv = vv; tv; tv = NEXT(tv) ) { @@ -2445,6 +2458,14 @@ void nd_gr_trace(LIST f,LIST v,int trace,int homo,stru get_vars((Obj)f,&fv); pltovl(v,&vv); for ( nvar = 0, tv = vv; tv; tv = NEXT(tv), nvar++ ); + switch ( ord->id ) { + case 1: + if ( ord->nv != nvar ) + error("nd_gr_trace : invalid order specification"); + break; + default: + break; + } nocheck = 0; mindex = 0;