[BACK]Return to mklookup.c CVS log [TXT][DIR] Up to [local] / OpenXM / src / kan96xx / Kan

Annotation of OpenXM/src/kan96xx/Kan/mklookup.c, Revision 1.1.1.1

1.1       maekawa     1: #include <stdio.h>
                      2: #include "datatype.h"
                      3: #include "stackm.h"
                      4:
                      5: /* Refer to global.c. You need to keep the orders of names and values */
                      6: main() {
                      7:   int i,j;
                      8:   char *names[]={"Snull","Sinteger","Sstring","SexecutableArray","Soperator",
                      9:                 "Sdollar","Sarray","SleftBraceTag","SrightBraceTag","Spoly",
                     10:                   "SarrayOfPOLY","SmatrixOfPOLY","Slist","Sfile","Sring",
                     11:                 "SuniversalNumber","SrationalFunction","Sclass","Sdouble"};
                     12:   int values[]={Snull,Sinteger,Sstring,SexecutableArray,Soperator,
                     13:                 Sdollar,Sarray,SleftBraceTag,SrightBraceTag,Spoly,
                     14:                   SarrayOfPOLY,SmatrixOfPOLY,Slist,Sfile,Sring,
                     15:                  SuniversalNumber,SrationalFunction,Sclass,Sdouble};
                     16:   for (i=0; i<TYPES; i++) {
                     17:     if (values[i] != i) {
                     18:       fprintf(stderr,"Errors in names and values\n");
                     19:       exit(100);
                     20:     }
                     21:     for (j=0; j<TYPES; j++) {
                     22:       printf("#define %s%s %d\n",names[i],names[j],values[i]*TYPES+values[j]);
                     23:     }
                     24:   }
                     25:   exit(0);
                     26: }
                     27:
                     28:

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>