base mag_get_fmpq on arf instead of fmpr

This commit is contained in:
Fredrik Johansson 2016-02-25 02:40:10 +01:00
parent 3bc3c9e895
commit 1e2333c48b

View file

@ -24,14 +24,13 @@
******************************************************************************/
#include "mag.h"
#include "arf.h"
void
mag_get_fmpq(fmpq_t y, const mag_t x)
{
fmpr_t t;
fmpr_init(t);
mag_get_fmpr(t, x);
fmpr_get_fmpq(y, t);
fmpr_clear(t);
arf_t t;
arf_init_set_mag_shallow(t, x);
arf_get_fmpq(y, t);
}