Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: use slong instead of long for arb accuracy #37

Merged
merged 1 commit into from
Dec 14, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/flint/_flint.pxd
Original file line number Diff line number Diff line change
Expand Up @@ -969,8 +969,8 @@ cdef extern from "arb.h":
void arb_get_ubound_arf(arf_t u, const arb_t z, long prec)
void arb_get_lbound_arf(arf_t u, const arb_t z, long prec)
void arb_nonnegative_part(arb_t u, const arb_t x)
long arb_rel_error_bits(const arb_t x)
long arb_rel_accuracy_bits(const arb_t x)
slong arb_rel_error_bits(const arb_t x)
slong arb_rel_accuracy_bits(const arb_t x)
long arb_bits(const arb_t x)
void arb_randtest_exact(arb_t x, flint_rand_t state, long prec, long mag_bits)
void arb_randtest_wide(arb_t x, flint_rand_t state, long prec, long mag_bits)
Expand Down
6 changes: 3 additions & 3 deletions src/flint/functions.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@ cdef goodstr(x):
return x.str(radius=False)
raise TypeError("must have arb or acb")

def good(func, long prec=0, long maxprec=0, long dps=0,
long maxdps=0, long padding=10, bint verbose=False, bint show=False, bint parts=True, metric=None):
def good(func, slong prec=0, slong maxprec=0, slong dps=0,
slong maxdps=0, slong padding=10, bint verbose=False, bint show=False, bint parts=True, metric=None):
"""
Evaluates *func*, automatically increasing the precision to get
a result accurate to the current working precision (or the
Expand Down Expand Up @@ -53,7 +53,7 @@ def good(func, long prec=0, long maxprec=0, long dps=0,


"""
cdef long orig, morebits, acc
cdef slong orig, morebits, acc

if dps > 0:
prec = dps_to_prec(dps)
Expand Down