| version 1.5, 2000/01/25 05:07:11 |
version 1.7, 2001/04/15 07:55:07 |
|
|
| /*$OpenXM: OpenXM/src/kan96xx/plugin/cmo.c,v 1.4 1999/11/27 01:41:11 takayama Exp $*/ |
/*$OpenXM: OpenXM/src/kan96xx/plugin/cmo.c,v 1.6 2000/02/02 03:30:48 takayama Exp $*/ |
| #include <stdio.h> |
#include <stdio.h> |
| #include <string.h> |
#include <string.h> |
| /* #include <netinet/in.h> */ |
/* #include <netinet/in.h> */ |
| Line 692 void cmoObjectToCmo00(struct object ob) |
|
| Line 692 void cmoObjectToCmo00(struct object ob) |
|
| /* cmoObjectToCmo00(KopIndeterminate(ob)); Old code. */ |
/* cmoObjectToCmo00(KopIndeterminate(ob)); Old code. */ |
| /* If you need to translate the name, do it here. */ |
/* If you need to translate the name, do it here. */ |
| if (CmoClientMode) { |
if (CmoClientMode) { |
| ob = KopIndeterminate(ob); |
ob = KopIndeterminate(ob); |
| }else{ |
}else{ |
| ob = cmoTranslateVariable_outGoing(KopIndeterminate(ob)); |
ob = cmoTranslateVariable_outGoing(KopIndeterminate(ob)); |
| } |
} |
| cmoObjectToCmo00(ob); |
cmoObjectToCmo00(ob); |
| break; |
break; |
| Line 707 void cmoObjectToCmo00(struct object ob) |
|
| Line 707 void cmoObjectToCmo00(struct object ob) |
|
| vlist = getoa(ob,0); |
vlist = getoa(ob,0); |
| vlist0 = newObjectArray(getoaSize(vlist)); |
vlist0 = newObjectArray(getoaSize(vlist)); |
| for (i=0; i<getoaSize(vlist); i++) { |
for (i=0; i<getoaSize(vlist); i++) { |
| if (CmoClientMode) { |
if (getoa(vlist,i).tag == Sdollar) { |
| putoa(vlist0,i, |
if (CmoClientMode) { |
| KpoIndeterminate(getoa(vlist,i))); |
putoa(vlist0,i, |
| }else{ |
KpoIndeterminate(getoa(vlist,i))); |
| putoa(vlist0,i, |
}else{ |
| KpoIndeterminate(cmoTranslateVariable_outGoing(getoa(vlist,i)))); |
putoa(vlist0,i, |
| } |
KpoIndeterminate(cmoTranslateVariable_outGoing(getoa(vlist,i)))); |
| |
} |
| |
}else{ |
| |
putoa(vlist0,i,getoa(vlist,i)); |
| |
} |
| } |
} |
| cmoObjectToCmo00(vlist0); /* output the list of variables. */ |
cmoObjectToCmo00(vlist0); /* output the list of variables. */ |
| cmoObjectToCmo00(getoa(ob,1)); /* output the body of the recursive poly |
cmoObjectToCmo00(getoa(ob,1)); /* output the body of the recursive poly |
| Line 956 struct object cmoCmoToObject00(struct cmoBuffer *cb) |
|
| Line 960 struct object cmoCmoToObject00(struct cmoBuffer *cb) |
|
| for (i=0; i<getoaSize(vlist0); i++) { |
for (i=0; i<getoaSize(vlist0); i++) { |
| ob1 = getoa(vlist0,i); |
ob1 = getoa(vlist0,i); |
| if (ectag(ob1) == CLASSNAME_indeterminate) { |
if (ectag(ob1) == CLASSNAME_indeterminate) { |
| ob1 = KopIndeterminate(ob1); |
ob1 = KopIndeterminate(ob1); |
| } |
}else if (ectag(ob1) == CLASSNAME_tree) { |
| |
/* do nothing. */ |
| |
} |
| putoa(vlist,i,ob1); |
putoa(vlist,i,ob1); |
| } |
} |
| /* vlist is a list of variables by strings. */ |
/* vlist is a list of variables by strings. */ |
| Line 1443 void *KSmathCapByStruct(void) |
|
| Line 1449 void *KSmathCapByStruct(void) |
|
| mathcap->sm[8] = SM_setMathCap; |
mathcap->sm[8] = SM_setMathCap; |
| mathcap->sm[9] = SM_getsp; |
mathcap->sm[9] = SM_getsp; |
| mathcap->sm[10] = SM_dupErrors; |
mathcap->sm[10] = SM_dupErrors; |
| mathcap->smSize = 11; |
mathcap->sm[11] = SM_pushCMOtag; |
| |
mathcap->smSize = 12; |
| |
|
| return((void *)mathcap); |
return((void *)mathcap); |
| } |
} |