Skip to content

Commit

Permalink
make sagelib build with flint3
Browse files Browse the repository at this point in the history
  • Loading branch information
mezzarobba committed Jun 29, 2023
1 parent 0e29994 commit b7ca9e4
Show file tree
Hide file tree
Showing 31 changed files with 216 additions and 176 deletions.
2 changes: 0 additions & 2 deletions pkgs/sage-conf/_sage_conf/_conf.py.in
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,6 @@ MAXIMA_FAS = "@SAGE_MAXIMA_FAS@".replace('${prefix}', SAGE_LOCAL)
# Delete this line if your ECL can load Kenzo without further prodding.
KENZO_FAS = "@SAGE_KENZO_FAS@".replace('${prefix}', SAGE_LOCAL)

ARB_LIBRARY = "@SAGE_ARB_LIBRARY@"

NTL_INCDIR = "@NTL_INCDIR@"
NTL_LIBDIR = "@NTL_LIBDIR@"

Expand Down
6 changes: 1 addition & 5 deletions src/sage/env.py
Original file line number Diff line number Diff line change
Expand Up @@ -223,7 +223,6 @@ def var(key: str, *fallbacks: Optional[str], force: bool = False) -> Optional[st
FOURTITWO_PPI = var("FOURTITWO_PPI")
FOURTITWO_CIRCUITS = var("FOURTITWO_CIRCUITS")
FOURTITWO_GROEBNER = var("FOURTITWO_GROEBNER")
ARB_LIBRARY = var("ARB_LIBRARY", "arb")
CBLAS_PC_MODULES = var("CBLAS_PC_MODULES", "cblas:openblas:blas")
ECL_CONFIG = var("ECL_CONFIG", "ecl-config")
NTL_INCDIR = var("NTL_INCDIR")
Expand Down Expand Up @@ -356,8 +355,7 @@ def cython_aliases(required_modules=None,
sage: cython_aliases()
{...}
sage: sorted(cython_aliases().keys())
['ARB_LIBRARY',
'CBLAS_CFLAGS',
['CBLAS_CFLAGS',
...,
'ZLIB_LIBRARIES']
sage: cython_aliases(required_modules=('module-that-is-assumed-to-not-exist'))
Expand Down Expand Up @@ -475,8 +473,6 @@ def uname_specific(name, value, alternative):
if "LINBOX_CFLAGS" in aliases:
aliases["LINBOX_CFLAGS"].append("-std=gnu++11")

aliases["ARB_LIBRARY"] = ARB_LIBRARY

# TODO: Remove Cygwin hack by installing a suitable cblas.pc
if os.path.exists('/usr/lib/libblas.dll.a'):
aliases["CBLAS_LIBS"] = ['gslcblas']
Expand Down
2 changes: 1 addition & 1 deletion src/sage/libs/arb/acb.pxd
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# distutils: libraries = gmp flint ARB_LIBRARY
# distutils: libraries = gmp flint
# distutils: depends = acb.h

from sage.libs.arb.types cimport *
Expand Down
2 changes: 1 addition & 1 deletion src/sage/libs/arb/acb_calc.pxd
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# distutils: libraries = gmp flint ARB_LIBRARY
# distutils: libraries = gmp flint
# distutils: depends = acb_calc.h

from sage.libs.arb.types cimport *
Expand Down
2 changes: 1 addition & 1 deletion src/sage/libs/arb/acb_elliptic.pxd
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# distutils: libraries = gmp flint ARB_LIBRARY
# distutils: libraries = gmp flint
# distutils: depends = acb_elliptic.h

from sage.libs.arb.types cimport *
Expand Down
2 changes: 1 addition & 1 deletion src/sage/libs/arb/acb_hypgeom.pxd
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# distutils: libraries = gmp flint ARB_LIBRARY
# distutils: libraries = gmp flint
# distutils: depends = acb_hypgeom.h

from sage.libs.arb.types cimport *
Expand Down
2 changes: 1 addition & 1 deletion src/sage/libs/arb/acb_modular.pxd
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# distutils: libraries = gmp flint ARB_LIBRARY
# distutils: libraries = gmp flint
# distutils: depends = acb_modular.h

from sage.libs.arb.types cimport *
Expand Down
20 changes: 1 addition & 19 deletions src/sage/libs/arb/acb_poly.pxd
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# distutils: libraries = gmp flint ARB_LIBRARY
# distutils: libraries = gmp flint
# distutils: depends = acb_poly.h

from sage.libs.arb.types cimport *
Expand Down Expand Up @@ -79,24 +79,10 @@ cdef extern from "arb_wrap.h":
void _acb_poly_divrem(acb_ptr Q, acb_ptr R, acb_srcptr A, long lenA, acb_srcptr B, long lenB, long prec)
bint acb_poly_divrem(acb_poly_t Q, acb_poly_t R, const acb_poly_t A, const acb_poly_t B, long prec)
void _acb_poly_div_root(acb_ptr Q, acb_t R, acb_srcptr A, long len, const acb_t c, long prec)
void _acb_poly_taylor_shift_horner(acb_ptr g, const acb_t c, long n, long prec)
void acb_poly_taylor_shift_horner(acb_poly_t g, const acb_poly_t f, const acb_t c, long prec)
void _acb_poly_taylor_shift_divconquer(acb_ptr g, const acb_t c, long n, long prec)
void acb_poly_taylor_shift_divconquer(acb_poly_t g, const acb_poly_t f, const acb_t c, long prec)
void _acb_poly_taylor_shift_convolution(acb_ptr g, const acb_t c, long n, long prec)
void acb_poly_taylor_shift_convolution(acb_poly_t g, const acb_poly_t f, const acb_t c, long prec)
void _acb_poly_taylor_shift(acb_ptr g, const acb_t c, long n, long prec)
void acb_poly_taylor_shift(acb_poly_t g, const acb_poly_t f, const acb_t c, long prec)
void _acb_poly_compose_horner(acb_ptr res, acb_srcptr poly1, long len1, acb_srcptr poly2, long len2, long prec)
void acb_poly_compose_horner(acb_poly_t res, const acb_poly_t poly1, const acb_poly_t poly2, long prec)
void _acb_poly_compose_divconquer(acb_ptr res, acb_srcptr poly1, long len1, acb_srcptr poly2, long len2, long prec)
void acb_poly_compose_divconquer(acb_poly_t res, const acb_poly_t poly1, const acb_poly_t poly2, long prec)
void _acb_poly_compose(acb_ptr res, acb_srcptr poly1, long len1, acb_srcptr poly2, long len2, long prec)
void acb_poly_compose(acb_poly_t res, const acb_poly_t poly1, const acb_poly_t poly2, long prec)
void _acb_poly_compose_series_horner(acb_ptr res, acb_srcptr poly1, long len1, acb_srcptr poly2, long len2, long n, long prec)
void acb_poly_compose_series_horner(acb_poly_t res, const acb_poly_t poly1, const acb_poly_t poly2, long n, long prec)
void _acb_poly_compose_series_brent_kung(acb_ptr res, acb_srcptr poly1, long len1, acb_srcptr poly2, long len2, long n, long prec)
void acb_poly_compose_series_brent_kung(acb_poly_t res, const acb_poly_t poly1, const acb_poly_t poly2, long n, long prec)
void _acb_poly_compose_series(acb_ptr res, acb_srcptr poly1, long len1, acb_srcptr poly2, long len2, long n, long prec)
void acb_poly_compose_series(acb_poly_t res, const acb_poly_t poly1, const acb_poly_t poly2, long n, long prec)
void _acb_poly_revert_series_lagrange(acb_ptr h, acb_srcptr f, long flen, long n, long prec)
Expand Down Expand Up @@ -161,10 +147,6 @@ cdef extern from "arb_wrap.h":
void acb_poly_exp_series_basecase(acb_poly_t f, const acb_poly_t h, long n, long prec)
void _acb_poly_exp_series(acb_ptr f, acb_srcptr h, long hlen, long n, long prec)
void acb_poly_exp_series(acb_poly_t f, const acb_poly_t h, long n, long prec)
void _acb_poly_sin_cos_series_basecase(acb_ptr s, acb_ptr c, acb_srcptr h, long hlen, long n, long prec, int times_pi)
void acb_poly_sin_cos_series_basecase(acb_poly_t s, acb_poly_t c, const acb_poly_t h, long n, long prec, int times_pi)
void _acb_poly_sin_cos_series_tangent(acb_ptr s, acb_ptr c, acb_srcptr h, long hlen, long n, long prec, int times_pi)
void acb_poly_sin_cos_series_tangent(acb_poly_t s, acb_poly_t c, const acb_poly_t h, long n, long prec, int times_pi)
void _acb_poly_sin_cos_series(acb_ptr s, acb_ptr c, acb_srcptr h, long hlen, long n, long prec)
void acb_poly_sin_cos_series(acb_poly_t s, acb_poly_t c, const acb_poly_t h, long n, long prec)
void _acb_poly_sin_series(acb_ptr s, acb_srcptr h, long hlen, long n, long prec)
Expand Down
2 changes: 1 addition & 1 deletion src/sage/libs/arb/arb.pxd
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# distutils: libraries = gmp flint ARB_LIBRARY
# distutils: libraries = gmp flint
# distutils: depends = arb.h

from sage.libs.arb.types cimport *
Expand Down
3 changes: 1 addition & 2 deletions src/sage/libs/arb/arb_fmpz_poly.pxd
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# distutils: libraries = gmp flint ARB_LIBRARY
# distutils: libraries = gmp flint
# distutils: depends = arb_fmpz_poly.h

from sage.libs.arb.types cimport *
Expand All @@ -22,5 +22,4 @@ cdef extern from "arb_wrap.h":
unsigned long arb_fmpz_poly_deflation(const fmpz_poly_t poly)
void arb_fmpz_poly_deflate(fmpz_poly_t res, const fmpz_poly_t poly, unsigned long deflation)
void arb_fmpz_poly_complex_roots(acb_ptr roots, const fmpz_poly_t poly, int flags, long prec)
void arb_fmpz_poly_cos_minpoly(fmpz_poly_t res, unsigned long n)
void arb_fmpz_poly_gauss_period_minpoly(fmpz_poly_t res, unsigned long q, unsigned long n)
2 changes: 1 addition & 1 deletion src/sage/libs/arb/arb_hypgeom.pxd
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# distutils: libraries = gmp flint ARB_LIBRARY
# distutils: libraries = gmp flint
# distutils: depends = arb_hypgeom.h

from sage.libs.flint.types cimport fmpz_t
Expand Down
26 changes: 13 additions & 13 deletions src/sage/libs/arb/arb_wrap.h
Original file line number Diff line number Diff line change
Expand Up @@ -11,19 +11,19 @@
#define ulong mp_limb_t
#define slong mp_limb_signed_t

#include <acb.h>
#include <acb_calc.h>
#include <acb_elliptic.h>
#include <acb_hypgeom.h>
#include <acb_mat.h>
#include <acb_modular.h>
#include <acb_poly.h>
#include <arb.h>
#include <arb_fmpz_poly.h>
#include <arb_hypgeom.h>
#include <arf.h>
#include <bernoulli.h>
#include <mag.h>
#include <flint/acb.h>
#include <flint/acb_calc.h>
#include <flint/acb_elliptic.h>
#include <flint/acb_hypgeom.h>
#include <flint/acb_mat.h>
#include <flint/acb_modular.h>
#include <flint/acb_poly.h>
#include <flint/arb.h>
#include <flint/arb_fmpz_poly.h>
#include <flint/arb_hypgeom.h>
#include <flint/arf.h>
#include <flint/bernoulli.h>
#include <flint/mag.h>

#undef ulong
#undef slong
Expand Down
4 changes: 1 addition & 3 deletions src/sage/libs/arb/arf.pxd
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# distutils: libraries = gmp flint ARB_LIBRARY
# distutils: libraries = gmp flint
# distutils: depends = arf.h

from sage.libs.arb.types cimport *
Expand Down Expand Up @@ -30,7 +30,6 @@ cdef extern from "arb_wrap.h":
void arf_set_ui(arf_t y, unsigned long x)
void arf_set_si(arf_t y, long x)
void arf_set_mpfr(arf_t y, const mpfr_t x)
# void arf_set_fmpr(arf_t y, const fmpr_t x)
void arf_set_d(arf_t y, double x)
void arf_swap(arf_t y, arf_t x)
void arf_init_set_ui(arf_t y, unsigned long x)
Expand All @@ -46,7 +45,6 @@ cdef extern from "arb_wrap.h":
int arf_set_round_fmpz_2exp(arf_t y, const fmpz_t x, const fmpz_t e, long prec, arf_rnd_t rnd)
void arf_get_fmpz_2exp(fmpz_t m, fmpz_t e, const arf_t x)
double arf_get_d(const arf_t x, arf_rnd_t rnd)
# void arf_get_fmpr(fmpr_t y, const arf_t x)
int arf_get_mpfr(mpfr_t y, const arf_t x, mpfr_rnd_t rnd)
void arf_get_fmpz(fmpz_t z, const arf_t x, arf_rnd_t rnd)
long arf_get_si(const arf_t x, arf_rnd_t rnd)
Expand Down
2 changes: 1 addition & 1 deletion src/sage/libs/arb/bernoulli.pxd
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# distutils: libraries = gmp flint ARB_LIBRARY
# distutils: libraries = gmp flint
# distutils: depends = bernoulli.h

from ..flint.types cimport fmpq_t, ulong
Expand Down
4 changes: 1 addition & 3 deletions src/sage/libs/arb/mag.pxd
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# distutils: libraries = gmp flint ARB_LIBRARY
# distutils: libraries = gmp flint
# distutils: depends = mag.h

from sage.libs.arb.types cimport *
Expand Down Expand Up @@ -27,13 +27,11 @@ cdef extern from "arb_wrap.h":
# void mag_randtest(mag_t x, flint_rand_t state, long expbits)
# void mag_randtest_special(mag_t x, flint_rand_t state, long expbits)
void mag_set_d(mag_t y, double x)
# void mag_set_fmpr(mag_t y, const fmpr_t x)
void mag_set_ui(mag_t y, unsigned long x)
void mag_set_fmpz(mag_t y, const fmpz_t x)
void mag_set_d_2exp_fmpz(mag_t z, double x, const fmpz_t y)
void mag_set_fmpz_2exp_fmpz(mag_t z, const fmpz_t x, const fmpz_t y)
void mag_set_ui_2exp_si(mag_t z, unsigned long x, long y)
# void mag_get_fmpr(fmpr_t y, const mag_t x)
void mag_get_fmpq(fmpq_t y, const mag_t x)
void mag_set_ui_lower(mag_t z, unsigned long x)
void mag_set_fmpz_lower(mag_t z, const fmpz_t x)
Expand Down
1 change: 1 addition & 0 deletions src/sage/libs/flint/flint_wrap.h
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@
#include <flint/fq.h>
#include <flint/fq_nmod.h>
#include <flint/nmod_poly.h>
#include <flint/nmod_poly_factor.h>
#include <flint/nmod_vec.h>
#include <flint/padic.h>
#include <flint/padic_poly.h>
Expand Down
2 changes: 2 additions & 0 deletions src/sage/libs/flint/fmpq.pxd
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ cdef extern from "flint_wrap.h":
fmpz * fmpq_denref(fmpq_t)
void fmpq_init(fmpq_t)
void fmpq_clear(fmpq_t)
void fmpq_init_set_readonly(fmpq_t, const mpq_t)
void fmpq_clear_readonly(fmpq_t)
void fmpq_one(fmpq_t)
void fmpq_zero(fmpq_t)
bint fmpq_is_zero(fmpq_t)
Expand Down
23 changes: 11 additions & 12 deletions src/sage/libs/flint/fmpq_poly.pxd
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,9 @@ cdef extern from "flint_wrap.h":
void fmpq_poly_canonicalise(fmpq_poly_t)
int fmpq_poly_is_canonical(const fmpq_poly_t)

void _fmpq_poly_set_length(fmpq_poly_t, slong)
void _fmpq_poly_normalise(fmpq_poly_t)

# Polynomial parameters
slong fmpq_poly_degree(const fmpq_poly_t)
ulong fmpq_poly_length(const fmpq_poly_t)
Expand All @@ -46,10 +49,7 @@ cdef extern from "flint_wrap.h":
void fmpq_poly_set_ui(fmpq_poly_t, ulong)
void fmpq_poly_set_fmpz(fmpq_poly_t, const fmpz_t)
void fmpq_poly_set_fmpq(fmpq_poly_t, const fmpq_t)
void fmpq_poly_set_mpz(fmpq_poly_t, const mpz_t)
void fmpq_poly_set_mpq(fmpq_poly_t, const mpq_t)
void fmpq_poly_set_fmpz_poly(fmpq_poly_t, const fmpz_poly_t)
void fmpq_poly_set_array_mpq(fmpq_poly_t, const mpq_t *, slong)

void fmpq_poly_set_str(fmpq_poly_t, const char *)
char *fmpq_poly_get_str(const fmpq_poly_t)
Expand All @@ -67,16 +67,13 @@ cdef extern from "flint_wrap.h":
void fmpq_poly_reverse(fmpq_poly_t, const fmpq_poly_t, slong)

void fmpq_poly_get_coeff_fmpq(fmpq_t, const fmpq_poly_t, slong)
void fmpq_poly_get_coeff_mpq(mpq_t, const fmpq_poly_t, slong)
void fmpq_poly_get_coeff_si(slong, const fmpq_poly_t, slong)
void fmpq_poly_get_coeff_ui(ulong, const fmpq_poly_t, slong)

void fmpq_poly_set_coeff_si(fmpq_poly_t, slong, slong)
void fmpq_poly_set_coeff_ui(fmpq_poly_t, slong, ulong)
void fmpq_poly_set_coeff_fmpz(fmpq_poly_t, slong, const fmpz_t)
void fmpq_poly_set_coeff_fmpq(fmpq_poly_t, slong, const fmpq_t)
void fmpq_poly_set_coeff_mpz(fmpq_poly_t, slong, const mpz_t)
void fmpq_poly_set_coeff_mpq(fmpq_poly_t, slong, const mpq_t)

# Comparison
int fmpq_poly_equal(const fmpq_poly_t, const fmpq_poly_t)
Expand All @@ -100,17 +97,13 @@ cdef extern from "flint_wrap.h":
fmpq_poly_t, const fmpq_poly_t, const fmpz_t)
void fmpq_poly_scalar_mul_fmpq(
fmpq_poly_t, const fmpq_poly_t, const fmpq_t)
void fmpq_poly_scalar_mul_mpz(fmpq_poly_t, const fmpq_poly_t, const mpz_t)
void fmpq_poly_scalar_mul_mpq(fmpq_poly_t, const fmpq_poly_t, const mpq_t)

void fmpq_poly_scalar_div_si(fmpq_poly_t, const fmpq_poly_t, slong)
void fmpq_poly_scalar_div_ui(fmpq_poly_t, const fmpq_poly_t, ulong)
void fmpq_poly_scalar_div_fmpz(
fmpq_poly_t, const fmpq_poly_t, const fmpz_t)
void fmpq_poly_scalar_div_fmpq(
fmpq_poly_t, const fmpq_poly_t, const fmpq_t)
void fmpq_poly_scalar_div_mpz(fmpq_poly_t, const fmpq_poly_t, const mpz_t)
void fmpq_poly_scalar_div_mpq(fmpq_poly_t, const fmpq_poly_t, const mpq_t)

# Multiplication
void fmpq_poly_mul(fmpq_poly_t, const fmpq_poly_t, const fmpq_poly_t)
Expand Down Expand Up @@ -155,8 +148,6 @@ cdef extern from "flint_wrap.h":
# Evaluation
void fmpq_poly_evaluate_fmpz(fmpq_t, const fmpq_poly_t, const fmpz_t)
void fmpq_poly_evaluate_fmpq(fmpq_t, const fmpq_poly_t, const fmpq_t)
void fmpq_poly_evaluate_mpz(mpq_t, const fmpq_poly_t, const mpz_t)
void fmpq_poly_evaluate_mpq(mpq_t, const fmpq_poly_t, const mpq_t)

# Composition
void fmpq_poly_compose(fmpq_poly_t, const fmpq_poly_t, const fmpq_poly_t)
Expand Down Expand Up @@ -189,3 +180,11 @@ cdef extern from "flint_wrap.h":
# since the fmpq_poly header seems to be lacking this inline function
cdef inline sage_fmpq_poly_max_limbs(const fmpq_poly_t poly):
return _fmpz_vec_max_limbs(fmpq_poly_numref(poly), fmpq_poly_length(poly))

# functions removed from flint but still needed in sage
cdef void fmpq_poly_scalar_mul_mpz(fmpq_poly_t, const fmpq_poly_t, const mpz_t)
cdef void fmpq_poly_scalar_mul_mpq(fmpq_poly_t, const fmpq_poly_t, const mpq_t)
cdef void fmpq_poly_set_coeff_mpq(fmpq_poly_t, slong, const mpq_t)
cdef void fmpq_poly_get_coeff_mpq(mpq_t, const fmpq_poly_t, slong)
cdef void fmpq_poly_set_mpz(fmpq_poly_t, const mpz_t)
cdef void fmpq_poly_set_mpq(fmpq_poly_t, const mpq_t)
45 changes: 45 additions & 0 deletions src/sage/libs/flint/fmpq_poly.pyx
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
# Functions removed from flint but still needed in Sage. Code adapted from
# earlier versions of flint.

from sage.libs.gmp.mpq cimport *
from sage.libs.flint.fmpz cimport *
from sage.libs.flint.fmpq cimport *

cdef void fmpq_poly_scalar_mul_mpz(fmpq_poly_t rop, const fmpq_poly_t op, const mpz_t c):
cdef fmpz_t f;
fmpz_init_set_readonly(f, c);
fmpq_poly_scalar_mul_fmpz(rop, op, f);
fmpz_clear_readonly(f);

cdef void fmpq_poly_scalar_mul_mpq(fmpq_poly_t rop, const fmpq_poly_t op, const mpq_t c):
cdef fmpq_t f;
fmpq_init_set_readonly(f, c);
fmpq_poly_scalar_mul_fmpq(rop, op, f);
fmpq_clear_readonly(f);

cdef void fmpq_poly_set_coeff_mpq(fmpq_poly_t poly, slong n, const mpq_t x):
cdef fmpq_t t;
fmpq_init_set_readonly(t, x);
fmpq_poly_set_coeff_fmpq(poly, n, t);
fmpq_clear_readonly(t);

cdef void fmpq_poly_get_coeff_mpq(mpq_t x, const fmpq_poly_t poly, slong n):
cdef fmpq_t t;
fmpq_init(t);
fmpq_poly_get_coeff_fmpq(t, poly, n);
fmpq_get_mpq(x, t);
fmpq_clear(t);

cdef void fmpq_poly_set_mpq(fmpq_poly_t poly, const mpq_t x):
fmpq_poly_fit_length(poly, 1);
fmpz_set_mpz(fmpq_poly_numref(poly), mpq_numref(x));
fmpz_set_mpz(fmpq_poly_denref(poly), mpq_denref(x));
_fmpq_poly_set_length(poly, 1);
_fmpq_poly_normalise(poly);

cdef void fmpq_poly_set_mpz(fmpq_poly_t poly, const mpz_t x):
fmpq_poly_fit_length(poly, 1);
fmpz_set_mpz(fmpq_poly_numref(poly), x);
fmpz_one(fmpq_poly_denref(poly));
_fmpq_poly_set_length(poly, 1);
_fmpq_poly_normalise(poly);
3 changes: 3 additions & 0 deletions src/sage/libs/flint/fmpz.pxd
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@ cdef extern from "flint_wrap.h":
void fmpz_init_set(fmpz_t, fmpz_t)
void fmpz_init_set_ui(fmpz_t, ulong)

void fmpz_init_set_readonly(fmpz_t, const mpz_t)
void fmpz_clear_readonly(fmpz_t)

# Conversion
void fmpz_set(fmpz_t f, fmpz_t g)
void fmpz_set_ui(fmpz_t, ulong)
Expand Down
Loading

0 comments on commit b7ca9e4

Please sign in to comment.