10#define MAX_BB_TYPES 256
16#define BLACKBOX_OFFSET (MAX_TOK+1)
28 WerrorS(
"missing blackbox_destroy");
32 WerrorS(
"missing blackbox_String");
37 WerrorS(
"missing blackbox_Copy");
45 && (
l->Data()!=r->
Data()))
47 b->blackbox_destroy(
b,(
void*)
l->Data());
51 l->data=
b->blackbox_Copy(
b,r->
Data());
57 char *
s=
b->blackbox_String(
b,d);
68 WerrorS(
"blackbox_serialize is not implemented");
74 WerrorS(
"blackbox_deserialize is not implemented");
119 res->data=
b->blackbox_String(
b,args->
Data());
126 if (ret)
return TRUE;
127 char *s2=(
char*)
omAlloc(strlen((
char*)
res->data)+strlen((
char*)res2.
data)+1);
128 sprintf(s2,
"%s%s",(
char*)
res->data,(
char*)res2.
data);
169 WerrorS(
"too many bb types defined");
250 list_struct->
list =
l;
struct blackbox_list * getBlackboxTypes()
return array of all define types.
int setBlackboxStuff(blackbox *bb, const char *n)
define a new type
BOOLEAN blackboxDefaultOp2(int, leftv, leftv, leftv)
default procedure blackboxDefaultOp2, to be called as "default:" branch
const char * getBlackboxName(const int t)
return the name to the type given by t (r/o)
void removeBlackboxStuff(const int rt)
void * blackbox_default_Copy(blackbox *, void *)
char * blackbox_default_String(blackbox *, void *)
BOOLEAN blackbox_default_serialize(blackbox *, void *, si_link)
BOOLEAN blackboxDefaultOp3(int, leftv, leftv, leftv, leftv)
default procedure blackboxDefaultOp3, to be called as "default:" branch
blackbox * getBlackboxStuff(const int t)
return the structure to the type given by t
BOOLEAN blackbox_default_Check(blackbox *, leftv, leftv)
BOOLEAN blackbox_default_Assign(leftv l, leftv r)
void blackbox_default_Print(blackbox *b, void *d)
default procedure blackbox_default_Print: print the string
void * blackbox_default_Init(blackbox *)
int blackboxIsCmd(const char *n, int &tok)
used by scanner: returns ROOT_DECL for known types (and the type number in tok)
static GLOBAL_VAR char * blackboxName[MAX_BB_TYPES]
BOOLEAN blackbox_default_deserialize(blackbox **, void **, si_link)
void blackbox_default_destroy(blackbox *, void *)
static GLOBAL_VAR int blackboxTableCnt
void printBlackboxTypes()
list all defined type (for debugging)
BOOLEAN blackboxDefaultOpM(int op, leftv res, leftv args)
default procedure blackboxDefaultOpM, to be called as "default:" branch
BOOLEAN blackboxDefaultOp1(int op, leftv l, leftv r)
default procedure blackboxDefaultOp1, to be called as "default:" branch
static GLOBAL_VAR blackbox * blackboxTable[MAX_BB_TYPES]
struct for containing list of blackbox names and the number of them.
Class used for (list of) interpreter objects.
void CleanUp(ring r=currRing)
const CanonicalForm int s
void WerrorS(const char *s)
BOOLEAN iiExprArithM(leftv res, leftv a, int op)
BOOLEAN jjLIST_PL(leftv res, leftv v)
void PrintS(const char *s)