=================================================================== RCS file: /home/cvs/OpenXM_contrib2/asir2000/parse/comp.c,v retrieving revision 1.2 retrieving revision 1.9 diff -u -p -r1.2 -r1.9 --- OpenXM_contrib2/asir2000/parse/comp.c 2000/08/21 08:31:46 1.2 +++ OpenXM_contrib2/asir2000/parse/comp.c 2015/08/06 10:01:53 1.9 @@ -23,7 +23,7 @@ * shall be made on your publication or presentation in any form of the * results obtained by use of the SOFTWARE. * (4) In the event that you modify the SOFTWARE, you shall notify FLL by - * e-mail at risa-admin@flab.fujitsu.co.jp of the detailed specification + * e-mail at risa-admin@sec.flab.fujitsu.co.jp of the detailed specification * for such modification or the source code of the modified part of the * SOFTWARE. * @@ -45,12 +45,12 @@ * DEVELOPER SHALL HAVE NO LIABILITY IN CONNECTION WITH THE USE, * PERFORMANCE OR NON-PERFORMANCE OF THE SOFTWARE. * - * $OpenXM: OpenXM_contrib2/asir2000/parse/comp.c,v 1.1.1.1 1999/12/03 07:39:11 noro Exp $ + * $OpenXM: OpenXM_contrib2/asir2000/parse/comp.c,v 1.8 2003/08/23 01:42:52 noro Exp $ */ #include "ca.h" #include "parse.h" #include "comp.h" -#if defined(THINK_C) || defined(VISUAL) +#if defined(__GNUC__) || defined(VISUAL) || defined(__MINGW32__) || defined(__MINGW64__) || (defined(__MACH__) && defined(__ppc__)) || defined(__FreeBSD__) #include #else #include @@ -58,12 +58,13 @@ extern f_return; -#if defined(THINK_C) || defined(VISUAL) +#if defined(__GNUC__) || defined(VISUAL) || defined(__MINGW32__) || defined(__MINGW64__) || (defined(__MACH__) && defined(__ppc__)) || defined(__FreeBSD__) void call_usrf(FUNC f,...) { va_list ap; int ac,i; pointer *c; + VS prev_mpvs; NODE tn; va_start(ap,f); @@ -71,6 +72,10 @@ void call_usrf(FUNC f,...) notdef(0,0,0,0); else { pushpvs(f); + if ( f->f.usrf->module ) { + prev_mpvs = MPVS; + MPVS = f->f.usrf->module->pvs; + } ac = va_arg(ap,int); for ( i = 0, tn = f->f.usrf->args; i < ac; i++, tn = NEXT(tn) ) @@ -78,6 +83,8 @@ void call_usrf(FUNC f,...) c = va_arg(ap,pointer *); *c = evalstat(BDY(f->f.usrf)); va_end(ap); f_return = 0; poppvs(); + if ( f->f.usrf->module ) + MPVS = prev_mpvs; } } #else @@ -88,6 +95,7 @@ va_dcl int ac,i; FUNC f; pointer a,b,*c; + VS prev_mpvs; NODE tn; va_start(ap); f = va_arg(ap,FUNC); @@ -95,12 +103,18 @@ va_dcl notdef(0,0,0,0); else { pushpvs(f); + if ( f->f.usrf->module ) { + prev_mpvs = MPVS; + MPVS = f->f.usrf->module->pvs; + } ac = va_arg(ap,int); for ( i = 0, tn = f->f.usrf->args; i < ac; i++, tn = NEXT(tn) ) ASSPV((int)FA0((FNODE)BDY(tn)),va_arg(ap,pointer)); c = va_arg(ap,pointer *); *c = evalstat(BDY(f->f.usrf)); f_return = 0; poppvs(); + if ( f->f.usrf->module ) + MPVS = prev_mpvs; } } #endif