1 | #ifndef STRUCTS_H |
---|
2 | #define STRUCTS_H |
---|
3 | /**************************************** |
---|
4 | * Computer Algebra System SINGULAR * |
---|
5 | ****************************************/ |
---|
6 | /* $Id: structs.h,v 1.7 1998-01-16 14:29:57 krueger Exp $ */ |
---|
7 | /* |
---|
8 | * ABSTRACT |
---|
9 | */ |
---|
10 | |
---|
11 | /* standard types */ |
---|
12 | typedef unsigned char uchar ; |
---|
13 | typedef unsigned short CARDINAL; |
---|
14 | typedef short BOOLEAN; |
---|
15 | |
---|
16 | typedef void * Sy_reference; |
---|
17 | #define ADDRESS Sy_reference |
---|
18 | #define BITSET unsigned int |
---|
19 | |
---|
20 | enum tHomog |
---|
21 | { |
---|
22 | isNotHomog = FALSE, |
---|
23 | isHomog = TRUE, |
---|
24 | testHomog |
---|
25 | }; |
---|
26 | /* C++-part */ |
---|
27 | #ifdef __cplusplus |
---|
28 | class ip_smatrix; |
---|
29 | class idrec; |
---|
30 | class intvec; |
---|
31 | class sleftv; |
---|
32 | class slists; |
---|
33 | class sattr; |
---|
34 | class skStrategy; |
---|
35 | class ssyStrategy; |
---|
36 | class procinfo; |
---|
37 | |
---|
38 | struct sip_sring; |
---|
39 | struct sip_sideal; |
---|
40 | struct sip_link; |
---|
41 | struct spolynom; |
---|
42 | struct _ssubexpr; |
---|
43 | struct _sssym; |
---|
44 | struct snumber; |
---|
45 | struct sip_command; |
---|
46 | struct sip_package; |
---|
47 | struct s_si_link_extension; |
---|
48 | struct reca; |
---|
49 | |
---|
50 | typedef struct _ssubexpr sSubexpr; |
---|
51 | typedef struct _sssym ssym; |
---|
52 | typedef struct spolyrec polyrec; |
---|
53 | typedef struct snumber rnumber; |
---|
54 | typedef struct sip_sideal ip_sideal; |
---|
55 | typedef struct sip_smap ip_smap; |
---|
56 | typedef struct sip_sring ip_sring; |
---|
57 | typedef struct sip_link ip_link; |
---|
58 | typedef struct sip_command ip_command; |
---|
59 | typedef struct sip_package ip_package; |
---|
60 | |
---|
61 | |
---|
62 | /* the pointer types */ |
---|
63 | typedef ip_sring * ring; |
---|
64 | typedef int idtyp; |
---|
65 | typedef idrec * idhdl; |
---|
66 | typedef rnumber * number; |
---|
67 | typedef polyrec * poly; |
---|
68 | typedef poly * polyset; |
---|
69 | typedef ip_sideal * ideal; |
---|
70 | typedef ip_smap * map; |
---|
71 | typedef ip_link * si_link; |
---|
72 | typedef ideal * resolvente; |
---|
73 | typedef ip_smatrix * matrix; |
---|
74 | typedef sleftv * leftv; |
---|
75 | typedef slists * lists; |
---|
76 | typedef sSubexpr * Subexpr; |
---|
77 | typedef union uutypes utypes; |
---|
78 | typedef sattr * attr; |
---|
79 | typedef skStrategy * kStrategy; |
---|
80 | typedef ip_command * command; |
---|
81 | typedef ip_package * package; |
---|
82 | typedef struct s_si_link_extension *si_link_extension; |
---|
83 | typedef ssyStrategy * syStrategy; |
---|
84 | typedef struct reca * alg; |
---|
85 | typedef procinfo * procinfov; |
---|
86 | |
---|
87 | struct _scmdnames |
---|
88 | { |
---|
89 | char *name; |
---|
90 | short alias; |
---|
91 | short tokval; |
---|
92 | short toktype; |
---|
93 | }; |
---|
94 | typedef struct _scmdnames cmdnames; |
---|
95 | |
---|
96 | /* the function pointer types */ |
---|
97 | //typedef void (*numberproc)(number a,number b,number * c); |
---|
98 | typedef number (*numberfunc)(number a,number b); |
---|
99 | |
---|
100 | typedef void (*pSetmProc)(poly p); |
---|
101 | typedef int (*pLDegProc)(poly p, int *length); |
---|
102 | typedef int (*pFDegProc)(poly p); |
---|
103 | typedef int (*pCompProc)(poly p1, poly p2); |
---|
104 | typedef void (*spSpolyLoopProc)(poly p1, poly p2, poly m, poly spNoether); |
---|
105 | |
---|
106 | extern ring currRing; |
---|
107 | #endif |
---|
108 | |
---|
109 | /* |
---|
110 | ** 7. runtime procedures/global data |
---|
111 | */ |
---|
112 | |
---|
113 | /* 7.1 C-routines : */ |
---|
114 | |
---|
115 | #ifdef __cplusplus |
---|
116 | extern "C" { |
---|
117 | #endif |
---|
118 | void m2_end(short i); |
---|
119 | #ifdef __cplusplus |
---|
120 | } |
---|
121 | #endif |
---|
122 | |
---|
123 | /* 7.2 C++-routines : */ |
---|
124 | |
---|
125 | #ifdef __cplusplus |
---|
126 | int inits(void); |
---|
127 | void singular_help(char *str, BOOLEAN example); |
---|
128 | #ifdef buildin_help |
---|
129 | int singular_manual(char *str); |
---|
130 | #endif |
---|
131 | #ifdef buildin_rand |
---|
132 | extern int siSeed; |
---|
133 | int siRand(); |
---|
134 | #endif |
---|
135 | #endif |
---|
136 | |
---|
137 | /*the general set of std-options --> kutil.cc */ |
---|
138 | extern BITSET test; |
---|
139 | /*the general set of verbose-options --> febase.cc */ |
---|
140 | extern BITSET verbose; |
---|
141 | /*debugging the bison grammar --> grammar.cc*/ |
---|
142 | #ifdef YYDEBUG |
---|
143 | #if YYDEBUG |
---|
144 | extern int yydebug; |
---|
145 | #endif |
---|
146 | #endif |
---|
147 | |
---|
148 | #endif |
---|
149 | |
---|