1 // fprint() for cl_SV_ringelt.
7 #include "cl_SV_ringelt.h"
12 #include "cl_output.h"
14 void fprint (cl_ostream stream, const cl_ring& R, const cl_SV_ringelt& vector)
16 var const cl_print_flags& flags = cl_default_print_flags;
17 var uintL len = vector.length();
18 if (flags.vector_syntax == vsyntax_commonlisp) {
19 fprintchar(stream,'#');
20 fprintchar(stream,'(');
22 fprintchar(stream,'[');
23 for (var uintL i = 0; i < len; i++) {
25 if (flags.vector_syntax == vsyntax_algebraic)
26 fprintchar(stream,',');
27 fprintchar(stream,' ');
29 R->_fprint(stream,vector[i]);
31 if (flags.vector_syntax == vsyntax_commonlisp)
32 fprintchar(stream,')');
34 fprintchar(stream,']');