FixedPointNumbers.jl
FixedPointNumbers.jl copied to clipboard
Road to 1.0
I'd like to move the whole JuliaImages stack to version numbers >= 1.0 (see https://github.com/JuliaImages/Images.jl/issues/825). Let's use this issue to collect plans for breaking changes in the near future.
Breaking changes include things like renamings, returning a different value than we used to (e.g., #129 might qualify, though rounding errors are a big ambiguous), or removing externally-visible functionality. Bug fixes, new features, performance improvements, etc., do not count as breaking, though of course they are very welcome.
Although the specific implementation method needs to be discussed separately, "Overflow checked arithmetics #41" needs to be settled.
I am a speed demon as you know.:smiling_imp: I don't think it is good to throw exceptions during calculation. Perhaps what we need is something like Base.Checked. It would be nice to have a macro similar to @fastmath
, which allows the user to specify the types of methods, i.e. *op*
or checked_*op*
. Of course, I want them but I do never want to write them!
Decide #127
rand
should be return Array
instead of ReinterpretArray
for the moment(cf. #125).
I like the idea of it returning an Array. Though I also want to fix ReinterpreteArray. I'm thinking of writing a special iterator for it, I think that would theoretically solve the problem at least for the cases we care about in JuliaImages.
- Drop support for
Fixed{Int8,8}
and so on (cf. issue #155, PR #159)
My draft plan
cf. https://discourse.julialang.org/t/rfc-what-should-the-arithmetic-within-the-fixedpointnumbers-be/46697/43 https://discourse.julialang.org/t/rfc-what-should-the-arithmetic-within-the-fixedpointnumbers-be/46697/47
milestone v0.9.0
- [x] Change the default
*
forNormed
s towrapping_mul
(PR #236) - [ ] Move arithmetic definitions/implementations into a submodule
FixedPointNumbers.FixedPointArithmetic
(issue #239)- Export
FixedPointArithmetic
andBase
operators - Make
wrapping_*
andsaturating_*
public viaCheckedArithmeticCore
- Export
- [ ] Reserve the aliases for unsigned
Fixed
/signedNormed
(issue #228) - [ ] Update README
- Announce
checked_*
,wrapping_*
andsaturating_*
support - Preannounce unsigned
Fixed
/signedNormed
(issue #199)
- Announce
milestone v0.9.x
- Supports the rest of the issue #185
- Improve
Fixed
-->Fixed
/Normed
-->Normed
conversions (issue #140) - Add partial support for 3-arg
{wrapping|saturating}_{add|sub|mul}
- Change the type definitions to
Fixed{T<:Integer, f}
/Normed{T<:Integer, f}
internally- Open access to
Fixed{<:Unsigned}
/Normed{<:Signed}
only via their aliases - Block the use of
Fixed{<:Unsigned}
/Normed{<:Signed}
via constructors and promotions
- Open access to
- Add internal support for
Fixed{<:Unsigned}
/Normed{<:Signed}
milestone v0.10.0
- ~Make 2-/3-arg
wrapping_*
/saturating_*
public viaCheckedArithmeticCore
~ -> v0.9.0 - Support
Fixed{<:Unsigned}
/Normed{<:Signed}
officially- Force unsupported downstream packages to declare
Fixed{<:Signed}
/Normed{<:Unsigned}
- Force unsupported downstream packages to declare
- Drop support for
Fixed{Int8,8}
and so on- cf. issue #155, PR #159
milestone v0.11.0
- Determine the interface for using multiple types of arithmetic
milestone v1.0.0
- Remove deprecated stuff
My personal roadmap has not changed for three years. However, because so much elapsed time has passed, I have withdrawn the roadmap. In other words, I have removed some v0.9 milestone flags.
Therefore, we may be able to release v0.9 without the saturating_*
and so on. (I proposed them as a solution to a problem, but the parties to the problem have little interest in the development.)
Meanwhile, unsigned Fixed
is something I would like to see its definition by v0.9. (Its functionality can be implemented in downstream packages.)