Macaulay2 Engine
Loading...
Searching...
No Matches

◆ toString() [1/2]

std::string mpfr::mpreal::toString ( const std::string & format) const
inline

Definition at line 1779 of file mpreal.h.

1780{
1781 char *s = NULL;
1782 std::string out;
1783
1784 if( !format.empty() )
1785 {
1786 if(!(mpfr_asprintf(&s, format.c_str(), mpfr_srcptr()) < 0))
1787 {
1788 out = std::string(s);
1789
1790 mpfr_free_str(s);
1791 }
1792 }
1793
1794 return out;
1795}
::mpfr_srcptr mpfr_srcptr() const
Definition mpreal.h:1767
void size_t s
Definition m2-mem.cpp:271

References mpfr_srcptr(), s, and toString().