]> www.ginac.de Git - cln.git/blob - src/polynomial/cl_UP.h
Fix build breakage on Sparc.
[cln.git] / src / polynomial / cl_UP.h
1 // Internals of Univariate polynomials.
2
3 #ifndef _CL_UP_H
4 #define _CL_UP_H
5
6 #include "cln/univpoly.h"
7 #include "cln/output.h"
8
9 namespace cln {
10
11 extern cl_heap_univpoly_ring* cl_make_univpoly_ring (const cl_ring& r);
12
13 struct cl_varname_property : public cl_property {
14         SUBCLASS_cl_property();
15 public:
16         cl_symbol varname;
17         // Constructor.
18         cl_varname_property (const cl_symbol& k, const cl_symbol& v) : cl_property (k), varname (v) {}
19 };
20
21 // The property list key used to look up the varname.
22 extern cl_symbol cl_univpoly_varname_key;
23
24 static inline const cl_string get_varname (cl_heap_univpoly_ring* UPR)
25 {
26         cl_property* p = UPR->get_property(cl_univpoly_varname_key);
27         if (p)
28                 return ((cl_varname_property*)p)->varname;
29         else
30                 return default_print_flags.univpoly_varname;
31 }
32
33 }  // namespace cln
34
35 #endif /* _CL_UP_H */