]> www.ginac.de Git - cln.git/blob - src/real/output/cl_R_cprint.cc
Update to recently found large Mersenne prime.
[cln.git] / src / real / output / cl_R_cprint.cc
1 // print_real().
2
3 // General includes.
4 #include "base/cl_sysdep.h"
5
6 // Specification.
7 #include "cln/real_io.h"
8
9
10 // Implementation.
11
12 #include "cln/real.h"
13 #include "real/cl_R.h"
14 #include "cln/rational_io.h"
15 #include "cln/float_io.h"
16
17 namespace cln {
18
19 void print_real (std::ostream& stream, const cl_print_real_flags& flags, const cl_R& z)
20 {
21         if (rationalp(z)) {
22                 DeclareType(cl_RA,z);
23                 // rationale Zahl
24                 print_rational(stream,flags,z);
25         } else {
26                 DeclareType(cl_F,z);
27                 // Float
28                 print_float(stream,flags,z);
29         }
30 }
31
32 }  // namespace cln