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

stillwater-sc / universal / 26010460064
84%
master: 84%

Build:
Build:
LAST BUILD BRANCH: main
DEFAULT BRANCH: master
Ran 18 May 2026 03:02AM UTC
Jobs 1
Files 652
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

18 May 2026 02:34AM UTC coverage: 84.164% (-0.002%) from 84.166%
26010460064

push

github

web-flow
feat(edecimal): extend parse to decimal-point and scientific notation (#865)

* feat(edecimal): extend parse to decimal-point and scientific notation

Previously edecimal::parse only accepted integer literals matching
[+-]*[0-9]+ via std::regex_match.  Anything with a decimal point or
an exponent suffix was rejected, even when the value was exactly
representable as an integer ("3.14e2" = 314).

Switch the tokenizer to sw::universal::string_parse::scan_decimal_float
(the foundation from #838) which yields int_part, frac_part, and a
signed exp10.  The effective decimal exponent is exp10 - frac.size():
when non-negative, the value is an exact integer and we accept it; when
negative the value has fractional digits that edecimal cannot represent
without precision loss, so we reject ("3.14", "1.5e-100", "0.001").
This matches the issue spec's "preserve those digits exactly" rule.

Accepted forms now include:
  "42", "-1000"              -- integer (unchanged)
  "3.14e2",   "-2.5e1"       -- decimal point with shift to integer
  "1e10",     "1.5e10"       -- pure exponent or compatible
  "3.14e+200"                -- 201-digit exact integer
  "5.", ".5e1"               -- edge syntax that scan_decimal_float allows

Side effects:
- Call unpad() after parsing so "0042" / "0.0042e4" no longer carry
  leading-zero limbs.
- Collapse "-0" / "-0.0e5" to +0 (no negative zero).

operator>> hygiene (failbit + extraction guard) was already shipped in
#858 (Phase E of #835); the test file now also pins it.

Test (elastic/decimal/conversion/string_parse.cpp) extended to 9 groups:
- integer parse (canonical + large)
- scientific exact (with the 201-digit "3.14e+200" reference)
- decimal-point form that produces an integer
- fractional input rejected (3.14, -0.5, 0.001, 1.5e-100, 3.0, 10.50e0)
- malformed reject (empty, alpha, "1e", ".", "1.2.3", "1e3.5", "42x", "0x1F")
- negative-zero collapse
- operator>> failbit on bad token
- operator>> success on scientific token in w... (continued)

22 of 22 new or added lines in 1 file covered. (100.0%)

11 existing lines in 1 file now uncovered.

46727 of 55519 relevant lines covered (84.16%)

6421691.62 hits per line

Coverage Regressions

Lines Coverage ∆ File
11
31.07
-3.93% include/sw/universal/verification/test_suite_randoms.hpp
Jobs
ID Job ID Ran Files Coverage
1 26010460064.1 18 May 2026 03:02AM UTC 652
84.16
GitHub Action Run
Source Files on build 26010460064
  • Tree
  • List 652
  • Changed 4
  • Source Changed 1
  • Coverage Changed 4
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #26010460064
  • 861e6e60 on github
  • Prev Build on main (#26005819991)
  • Next Build on main (#26011539088)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc