TryFormat for the "ns" format returned false for any set that can
not be expressed as a caret/tilde range. The public ToString
routes through DefaultInterpolatedStringHandler, whose buffer-full
fallback re-enters ToString, causing an infinite loop / stack overflow.
For "ns", fall back to the full comparator ("n") form when the
compact form cannot represent the set, so the call always succeeds
for a representable range. A genuine buffer overflow still returns
false as before.
Add failing-then-passing tests.
28 lines
683 B
Markdown
28 lines
683 B
Markdown
# Changelog
|
|
|
|
All notable changes to this project will be documented in this file.
|
|
|
|
This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
|
|
## [1.0.0] - 2026-05-21
|
|
|
|
### Added
|
|
|
|
- This is the initial release of the library.
|
|
|
|
## [Unreleased]
|
|
|
|
### Added
|
|
|
|
### Changed
|
|
|
|
### Fixed
|
|
|
|
- Reject invalid SemVer identifiers when parsing versions.
|
|
- Range exact and non-equal comparators ignore build metadata when matching versions.
|
|
- Avoid infinite recursion when formatting ranges in the short npm (`ns`) form.
|
|
|
|
### Removed
|
|
|
|
[1.0.0]: https://code.geekeey.de/geekeey/semver/releases/tag/1.0.0
|
|
[Unreleased]: https://code.geekeey.de/geekeey/semver/compare/1.0.0...HEAD
|