quagmt / udecimal

A high-performance, high precision, zero allocation fixed-point decimal library for financial applications
https://quagmt.github.io/udecimal/
BSD 3-Clause "New" or "Revised" License
111 stars 4 forks source link

feat: add precUint #13

Closed quagmt closed 1 month ago

quagmt commented 1 month ago

Description

oneUnit := udecimal.MustParse("0.001")
a := udecimal.MustParse("1.123456")
b := a.Trunc(oneUnit.PrecUint()) // b = 1.123
codecov[bot] commented 1 month ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 94.55%. Comparing base (603c3aa) to head (a0189ad). Report is 1 commits behind head on master.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #13 +/- ## ======================================= Coverage 94.54% 94.55% ======================================= Files 5 5 Lines 1265 1267 +2 ======================================= + Hits 1196 1198 +2 Misses 37 37 Partials 32 32 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.