-
Notifications
You must be signed in to change notification settings - Fork 11
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
How to add functions? #48
Comments
I think it should be Float128(@ccall(libquadmath.fmodq(x::Cfloat128, y::Cfloat128)::Cfloat128)) |
Same question for complex functions libquadmath supports. quadmath.h:
--- from quadmath.jl ---
I think defining
|
Hi @JeffreySarnoff @simonbyrne # f(x)
function cutest_ufn_q_(status, n, x, f)
ptr_cutest_ufn_q_ = Libdl.dlsym(cutest_lib_quadruple, :cutest_ufn_q_)
@ccall $ptr_cutest_ufn_q_(status::Ptr{Cint}, n::Ptr{Cint}, x::Ptr{Cfloat128},
f::Ptr{Cfloat128})::Cvoid
end
# gradient(x)
function cutest_ugr_q_(status, n, x, g)
ptr_cutest_ugr_q_ = Libdl.dlsym(cutest_lib_quadruple, :cutest_ugr_q_)
@ccall $ptr_cutest_ugr_q_(status::Ptr{Cint}, n::Ptr{Cint}, x::Ptr{Cfloat128},
g::Ptr{Cfloat128})::Cvoid
end
function cutest_cint_uofg_q_(status, n, x, f, g, grad)
ptr_cutest_cint_uofg_q_ = Libdl.dlsym(cutest_lib_quadruple, :cutest_cint_uofg_q_)
@ccall $ptr_cutest_cint_uofg_q_(status::Ptr{Cint}, n::Ptr{Cint}, x::Ptr{Cfloat128}, f::Ptr{Cfloat128},
g::Ptr{Cfloat128}, grad::Ptr{Bool})::Cvoid
end I'm working on a new version of |
I do not how to do that. |
Have you tried using the generic |
I'm not sure what you are doing with the local version of
@ccall
.I'd like to add some functions via PR. I know how to do it this way:
How is this best done in keeping with the structure of the package?
The text was updated successfully, but these errors were encountered: