version 1.23, 2016/03/31 03:22:54 |
version 1.26, 2020/10/06 11:33:46 |
|
|
/* $OpenXM: OpenXM/src/kan96xx/Kan/primitive.c,v 1.22 2013/11/06 06:44:48 takayama Exp $ */ |
/* $OpenXM: OpenXM/src/kan96xx/Kan/primitive.c,v 1.25 2018/09/07 00:15:44 takayama Exp $ */ |
/* primitive.c */ |
/* primitive.c */ |
/* The functions in this module were in stackmachine.c */ |
/* The functions in this module were in stackmachine.c */ |
|
|
|
|
#include <stdlib.h> |
#include <stdlib.h> |
#include <string.h> |
#include <string.h> |
#include <signal.h> |
#include <signal.h> |
|
#include <time.h> |
|
#include <unistd.h> |
#include "datatype.h" |
#include "datatype.h" |
#include "stackm.h" |
#include "stackm.h" |
#include "extern.h" |
#include "extern.h" |
|
|
#include "kclass.h" |
#include "kclass.h" |
#include <sys/types.h> |
#include <sys/types.h> |
#include <sys/times.h> |
#include <sys/times.h> |
#include "../plugin/mysig.h" |
#include "mysig.h" |
|
|
int PrintDollar = 1; /* flag for printObject() */ |
int PrintDollar = 1; /* flag for printObject() */ |
int PrintComma = 1; /* flag for printObject() */ |
int PrintComma = 1; /* flag for printObject() */ |
Line 281 void printObject(ob,nl,fp) |
|
Line 283 void printObject(ob,nl,fp) |
|
printObjectList(&ob); |
printObjectList(&ob); |
break; |
break; |
case Sfile: |
case Sfile: |
fprintf(fp,"Name=%s, FILE *=%x ",ob.lc.str,(int) ob.rc.file); |
fprintf(fp,"Name=%s, FILE *=%p ",ob.lc.str,ob.rc.file); |
break; |
break; |
case Sring: |
case Sring: |
fprintf(fp,"Ring."); KshowRing(KopRingp(ob)); |
fprintf(fp,"Ring."); KshowRing(KopRingp(ob)); |
Line 454 int executePrimitive(ob) |
|
Line 456 int executePrimitive(ob) |
|
extern int KeepInput; |
extern int KeepInput; |
extern int History; |
extern int History; |
extern struct ring *CurrentRingp; |
extern struct ring *CurrentRingp; |
extern TimerOn; |
extern int TimerOn; |
extern SecureMode; |
extern int SecureMode; |
extern int RestrictedMode; |
extern int RestrictedMode; |
|
|
infixOn = 0; |
infixOn = 0; |
Line 1201 int executePrimitive(ob) |
|
Line 1203 int executePrimitive(ob) |
|
default: errorStackmachine("Usage:system"); |
default: errorStackmachine("Usage:system"); |
} |
} |
if (SecureMode) errorStackmachine("Security violation."); |
if (SecureMode) errorStackmachine("Security violation."); |
system( ob1.lc.str ); |
{int rr; rr=system( ob1.lc.str );} |
break; |
break; |
|
|
case Scat_n: |
case Scat_n: |