• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

stillwater-sc / universal / 29688711546
85%
master: 84%

Build:
Build:
LAST BUILD BRANCH: main
DEFAULT BRANCH: master
Ran 19 Jul 2026 02:04PM UTC
Jobs 1
Files 695
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

19 Jul 2026 01:21PM UTC coverage: 84.677% (-0.01%) from 84.689%
29688711546

push

github

web-flow
feat(efloat): implement decimal operator<< / to_string (was a 'TBD' stub) (#1150) (#1155)

* feat(efloat): implement decimal operator<< / to_string (was a 'TBD' stub) (#1150)

efloat's stream output printed the literal "TBD" for every finite value; only
inf/nan/zero worked. Implemented an arbitrary-precision binary->decimal formatter
(to_string + to_digits), ported from ereal: digits are extracted using efloat's
own arithmetic (scale to [1,10) via *10 / /10, then repeatedly take the leading
digit and multiply by 10), with round-to-nearest and carry propagation. Honors
the stream's precision/width and fixed/scientific/showpos/uppercase/internal/
left flags; operator<< now delegates to it (same structure as ereal's).

Sign uses sign()==-1, not isneg() (which is false for -inf), so -inf prints
correctly. Defined after the arithmetic operators it uses (forward-declared
before operator<<). Accuracy is bounded by the operand's working precision.

New elastic/efloat/conversion/to_string.cpp: no-TBD, std match for double-range
scientific values, high-precision round-trip (pi to 20/50/100 digits vs the
efloat_pi oracle), finite round-trips, fixed format, and special values (incl.
the -inf sign). Validated on gcc 13.3.0 and clang 18.1.3.

Resolves #1150

* fix(efloat): decimal output -- large exponents + fixed-format rounding (CodeRabbit #1155)

Two porting bugs in the new to_string:
- append_exponent used ereal's fixed-width e/100 digit math, which emits
  non-digit chars for |exponent| >= 1000. efloat's range far exceeds double's
  (it can print 1e1000), so switch to a generic std::to_string path with
  minimum-2-digit padding. (also resolves the Codacy static-analysis finding)
- the fixed path called round_string(t, nrDigitsForFixedFormat + 1, ...) and
  copied nrDigitsForFixedFormat digits, so it read the NUL terminator (never
  rounded) and emitted too many decimals for values < 1. Use nrDigits (the
  requested integerDigits + precision) as ereal does; the... (continued)

103 of 126 new or added lines in 1 file covered. (81.75%)

10 existing lines in 1 file now uncovered.

49536 of 58500 relevant lines covered (84.68%)

7050202.9 hits per line

Uncovered Changes

Lines Coverage ∆ File
23
87.48
-0.25% include/sw/universal/number/efloat/efloat_impl.hpp

Coverage Regressions

Lines Coverage ∆ File
10
31.43
-3.57% include/sw/universal/verification/test_suite_randoms.hpp
Jobs
ID Job ID Ran Files Coverage
1 29688711546.1 19 Jul 2026 02:04PM UTC 695
84.68
GitHub Action Run
Source Files on build 29688711546
  • Tree
  • List 695
  • Changed 3
  • Source Changed 1
  • Coverage Changed 3
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #29688711546
  • c0504a02 on github
  • Prev Build on main (#29686404407)
  • Next Build on main (#29689875238)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc