1 | #ifndef STRUCTS_H |
---|
2 | #define STRUCTS_H |
---|
3 | /**************************************** |
---|
4 | * Computer Algebra System SINGULAR * |
---|
5 | ****************************************/ |
---|
6 | /* $Id$ */ |
---|
7 | /* |
---|
8 | * ABSTRACT |
---|
9 | */ |
---|
10 | |
---|
11 | /* for omBin */ |
---|
12 | #include <omalloc/omalloc.h> |
---|
13 | #include <misc/auxiliary.h> |
---|
14 | #include <kernel/polys.h> |
---|
15 | #include <polys/coeffrings.h> |
---|
16 | |
---|
17 | #ifdef HAVE_RINGS |
---|
18 | #include <coeffs/si_gmp.h> |
---|
19 | #endif |
---|
20 | |
---|
21 | /* standard types */ |
---|
22 | #ifdef HAVE_RINGS |
---|
23 | typedef unsigned long NATNUMBER; |
---|
24 | typedef mpz_ptr int_number; |
---|
25 | #endif |
---|
26 | |
---|
27 | #define BITSET unsigned int |
---|
28 | |
---|
29 | |
---|
30 | /* C++-part */ |
---|
31 | #ifdef __cplusplus |
---|
32 | class sleftv; |
---|
33 | class procinfo; |
---|
34 | class skStrategy; |
---|
35 | class ssyStrategy; |
---|
36 | class CPolynomialSummator; |
---|
37 | class CGlobalMultiplier; |
---|
38 | class CFormulaPowerMultiplier; |
---|
39 | #endif |
---|
40 | |
---|
41 | struct sip_package; |
---|
42 | typedef struct sip_package ip_package; |
---|
43 | typedef ip_package * package; |
---|
44 | |
---|
45 | typedef struct n_Procs_s n_Procs_s; |
---|
46 | |
---|
47 | // #ifdef HAVE_PLURAL |
---|
48 | struct nc_struct; |
---|
49 | typedef struct nc_struct nc_struct; |
---|
50 | // #endif |
---|
51 | |
---|
52 | typedef struct sip_link ip_link; |
---|
53 | |
---|
54 | /* the pointer types */ |
---|
55 | typedef char * char_ptr; |
---|
56 | typedef int * int_ptr; |
---|
57 | |
---|
58 | #ifdef __cplusplus |
---|
59 | //typedef ip_link * si_link; |
---|
60 | typedef sleftv * leftv; |
---|
61 | //typedef slists * lists; |
---|
62 | //typedef sattr * attr; |
---|
63 | typedef skStrategy * kStrategy; |
---|
64 | typedef ssyStrategy * syStrategy; |
---|
65 | typedef procinfo * procinfov; |
---|
66 | |
---|
67 | /* the function pointer types */ |
---|
68 | |
---|
69 | class idrec; |
---|
70 | typedef idrec * idhdl; |
---|
71 | |
---|
72 | #endif /* __cplusplus */ |
---|
73 | |
---|
74 | |
---|
75 | |
---|
76 | /* |
---|
77 | ** 7. runtime procedures/global data |
---|
78 | */ |
---|
79 | |
---|
80 | /* 7.1 C-routines : */ |
---|
81 | |
---|
82 | |
---|
83 | #ifdef __cplusplus |
---|
84 | extern "C" { |
---|
85 | #endif |
---|
86 | void m2_end(int i) __attribute__((noreturn)); |
---|
87 | #ifdef __cplusplus |
---|
88 | } |
---|
89 | #endif |
---|
90 | |
---|
91 | /* 7.2 C++-routines : */ |
---|
92 | |
---|
93 | #ifdef __cplusplus |
---|
94 | int inits(void); |
---|
95 | int IsPrime(int i); |
---|
96 | extern int siSeed; |
---|
97 | int siRand(); |
---|
98 | #endif |
---|
99 | |
---|
100 | #define loop for(;;) |
---|
101 | |
---|
102 | #ifndef ABS |
---|
103 | #define ABS(x) ((x)<0?(-(x)):(x)) |
---|
104 | #endif |
---|
105 | |
---|
106 | extern omBin char_ptr_bin; |
---|
107 | |
---|
108 | #endif |
---|
109 | |
---|