JuliaMath / BFloat16s.jl

Julia implementation for the BFloat16 number type
Other
49 stars 17 forks source link

Allowing x % BFloat16 #72

Open JeffreySarnoff opened 7 months ago

JeffreySarnoff commented 7 months ago

maybe as a workaround

Base.rem(x::Real, ::Type{BFloat16}) = BFloat16(x)
giordano commented 2 months ago

I don't think Julia's rem allows rem(::Real, ::Type{AbstractFloat}), it should be defined only for Integer types.