Macaulay2 Engine
Loading...
Searching...
No Matches
reader.cpp
Go to the documentation of this file.
1#include "reader.hpp"
2
3// The following includes a definition for: i >> mpz_t
4#include "gmpxx.h"
5
6namespace M2 {
7
8template <>
10{
11 mpz_t a;
12 mpz_init(a);
13 i >> a;
14 mRing.set_from_mpz(result, a);
15 mpz_clear(a);
16}
17}
18
19// Local Variables:
20// compile-command: "make -C $M2BUILDDIR/Macaulay2/e "
21// indent-tabs-mode: nil
22// End:
const RingType & mRing
Definition reader.hpp:44
void read(std::istream &i, ElementType &result)
RingType::ElementType ElementType
Definition reader.hpp:38
VALGRIND_MAKE_MEM_DEFINED & result(result)
Definition aring-CC.cpp:3
M2::Reader<RingType> — parse a single ring element from a std::istream.