Skip to content

Commit 2e26583

Browse files
authored
use the versioned MPFR in ccalls (#59550)
The other `ccall`s to MPFR use the versioned lib name. I suppose the `ccall`s modified in this change were simply missed in PR #47676.
1 parent fd1c6fd commit 2e26583

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

base/irrationals.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -253,7 +253,7 @@ function irrational(sym, val, def)
253253
bigconvert = isa(def,Symbol) ? quote
254254
function Base.BigFloat(::Irrational{$qsym}, r::MPFR.MPFRRoundingMode=Rounding.rounding_raw(BigFloat); precision=precision(BigFloat))
255255
c = BigFloat(;precision=precision)
256-
ccall(($(string("mpfr_const_", def)), :libmpfr),
256+
ccall(($(string("mpfr_const_", def)), Base.MPFR.libmpfr),
257257
Cint, (Ref{BigFloat}, MPFR.MPFRRoundingMode), c, r)
258258
return c
259259
end

stdlib/Random/src/generation.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ function _rand!(rng::AbstractRNG, z::BigFloat, sp::SamplerBigFloat, ::CloseOpen0
8080
randbool = _rand!(rng, z, sp)
8181
z.exp = 0
8282
randbool &&
83-
ccall((:mpfr_sub_d, :libmpfr), Int32,
83+
ccall((:mpfr_sub_d, Base.MPFR.libmpfr), Int32,
8484
(Ref{BigFloat}, Ref{BigFloat}, Cdouble, Base.MPFR.MPFRRoundingMode),
8585
z, z, 0.5, Base.MPFR.ROUNDING_MODE[])
8686
z
@@ -91,7 +91,7 @@ end
9191
function _rand!(rng::AbstractRNG, z::BigFloat, sp::SamplerBigFloat, ::CloseOpen01{BigFloat},
9292
::Nothing)
9393
_rand!(rng, z, sp, CloseOpen12(BigFloat))
94-
ccall((:mpfr_sub_ui, :libmpfr), Int32, (Ref{BigFloat}, Ref{BigFloat}, Culong, Base.MPFR.MPFRRoundingMode),
94+
ccall((:mpfr_sub_ui, Base.MPFR.libmpfr), Int32, (Ref{BigFloat}, Ref{BigFloat}, Culong, Base.MPFR.MPFRRoundingMode),
9595
z, z, 1, Base.MPFR.ROUNDING_MODE[])
9696
z
9797
end

0 commit comments

Comments
 (0)