All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.
2.3.0 - 2021-09-18
- The CHANGELOG file in the npm package bundle.
- License from "WTFPL" to "Unlicense".
- Polish README.
- Typos in comments.
- Stale "resolutions" field in
package.json
.
2.2.0 - 2021-06-27
- Add contract name prefix to custom errors.
@param
tags for custom errors NatSpec.
2.1.0 - 2021-06-27
- Solidity v0.8.4 custom errors.
- Define the upper limit as
MAX_UD60x18 / SCALE
in thesqrt
function. - Define
xValue
var to avoid readingx.value
multiple times. - Move
SCALE > prod1
check at the top of themulDivFixedPoint
function. - Refer to
add
function operands as summands. - Refer to
sub
function operands as minuend and subtrahend. - Rename
rUnsigned
var torAbs
. - Set minimum compiler version to 0.8.4.
- Use
MIN_SD59x18
instead oftype(int256).min
where appropriate.
hardhat/console.sol
import.- Stale caveat in
sqrt
function NatSpec.
2.0.1 - 2021-06-16
- Mention the new typed flavours in the README.
- Code snippet for the UD60x18Typed consumer in the README.
- English typos in NatSpec comments.
- Minor bug in
log10
inPRBMathUD60x18Typed.sol
which made the result inaccurate when the input was a multiple of 10.
2.0.0 - 2021-06-14
- Addition and subtraction functions in the typed libraries.
- Gas estimates for
fromInt
,fromUint
,pow
,toInt
andtoUInt
. - Structs
PRBMath.SD59x18
andPRBMath.UD60x18
, simple wrappers to indicate that the variables are fixed-point numbers. - Typed versions of the library:
PRBMathSD59x18Typed.sol
andPRBMathUD60x18Typed.sol
.
- Increase the accuracy of
exp2
by using the 192.64-bit format instead of 128.128-bit. - Rename
PRBMathCommon.sol
toPRBMath.sol
. - Set named parameter instead of returning result in
pow
functions. - Update gas estimates for
exp
andexp2
.
- Bug in
log10
which made the result incorrect when the input was not a multiple of 10. - Typos in NatSpec comments.
1.1.0 - 2021-05-07 [YANKED]
- New convertor functions
fromInt
andtoInt
inPRBMathSD59x18.sol
. - New convertor functions
fromUint
andtoUint
inPRBMathUD60x18.sol
. - New function
mulDivSigned
inPRBMathCommon.sol
. - New function
pow
inPRBMathSD59x18.sol
andPRBMathUD60x18.sol
- Rename the previous
pow
function topowu
. - Speed up
exp2
by simplifying the integer part calculations. - Use the fixed-point format in NatSpec comments.
- Minor typos in NatSpec comments.
1.0.5 - 2021-04-24
- Link to StackExchange answer in
exp2
NatSpec comments.
- Speed up the
exp2
function in PRBMathCommon.sol by simplifying the integer part calculation. - Use
SCALE
instead of the 1e18 literal inPRBMathCommon.sol
.
1.0.4 - 2021-04-20
- Optimise the
pow
function in PRBMathUD60x18.sol by callingmulDivFixedPoint
directly.
1.0.3 - 2021-04-20
- Typos in NatSpec comments.
- Typo in example in README.
- Stale
SCALE_LPOTD
andSCALE_INVERSE
constants in PRBMathSD59x18.sol.
1.0.2 - 2021-04-19
- Stale
SCALE_LPOTD
andSCALE_INVERSE
constants in PRBMathUD60x18.sol.
1.0.1 - 2021-04-19
- Examples in the README.
1.0.0 - 2021-04-19
- First release of the library.