Skip to content

Adopt C++23#701

Merged
jviotti merged 8 commits intomainfrom
core-cpp23
Mar 31, 2026
Merged

Adopt C++23#701
jviotti merged 8 commits intomainfrom
core-cpp23

Conversation

@jviotti
Copy link
Copy Markdown
Member

@jviotti jviotti commented Mar 30, 2026

Signed-off-by: Juan Cruz Viotti jv@jviotti.com

Copy link
Copy Markdown

@cubic-dev-ai cubic-dev-ai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No issues found across 60 files

@augmentcode
Copy link
Copy Markdown

augmentcode bot commented Mar 30, 2026

🤖 Augment PR Summary

Summary: Updates the vendored sourcemeta/core subtree to commit 7e57b205…, bringing in C++23 adoption and several new/updated utilities.

Changes:

  • Bumps Core’s default C++ standard to C++23 and modernizes implementations to use C++23 APIs (e.g., std::ranges algorithms, std::to_chars/from_chars, std::unreachable, std::string::resize_and_overwrite).
  • Adds a new Core ip component with IPv4/IPv6 validators and integrates it into Core’s CMake options/config export.
  • Updates URI helpers to use the new IP validation (adds URI::is_ipv4(), tightens is_ipv6(), tracks IP-literal hosts for correct recomposition).
  • Adds std::formatter specializations for Core JSON and vocabularies to support std::format.
  • Refactors JSON/YAML/regex parsing and stringification paths to avoid locale-dependent conversions and reduce exception-based parsing.
  • Extends the URI template router to store per-route typed arguments and bumps the serialized router format version to v2, including read/write support.

Technical Notes: The update touches build/export wiring (new component + linkage), and introduces a new on-disk router format; downstream consumers may need to account for transitive dependencies and router version compatibility.

🤖 Was this summary useful? React with 👍 or 👎

Copy link
Copy Markdown

@augmentcode augmentcode bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review completed. 2 suggestions posted.

Fix All in Augment

Comment augment review to trigger a new review at any time.

sourcemeta_library_install(NAMESPACE sourcemeta PROJECT core NAME uri)
endif()

target_link_libraries(sourcemeta_core_uri
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

vendor/core/src/core/uri/CMakeLists.txt:10 — If BUILD_SHARED_LIBS=OFF, linking sourcemeta_core_uri to sourcemeta::core::ip as PRIVATE won’t propagate the dependency to consumers and can cause unresolved symbols (e.g., URI::is_ipv4() / URI::is_ipv6()). Consider whether this should be transitive to match config.cmake.in including sourcemeta_core_ip.cmake when the uri component is requested.

Severity: medium

Fix This in Augment

🤖 Was this useful? React with 👍 or 👎, or 🚀 if it prevented an incident/outage.

/// router
auto add(const std::string_view uri_template, const Identifier identifier)
-> void;
auto add(const std::string_view uri_template, const Identifier identifier,
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

vendor/core/src/core/uritemplate/include/sourcemeta/core/uritemplate_router.h:79add(..., arguments) stores Argument entries as std::string_view (and may store std::string_view values inside the variant), so callers now need to ensure argument name/value lifetimes outlive the router, not just uri_template. Without that, save()/arguments() can end up reading dangling views.

Severity: medium

Fix This in Augment

🤖 Was this useful? React with 👍 or 👎, or 🚀 if it prevented an incident/outage.

@jviotti jviotti changed the title Upgrade Code to 7e57b205a023bab5a3517864af7108614fd2e7bc Adopt C++23 Mar 30, 2026
Signed-off-by: Juan Cruz Viotti <jv@jviotti.com>
jviotti added 6 commits March 30, 2026 16:53
Signed-off-by: Juan Cruz Viotti <jv@jviotti.com>
Signed-off-by: Juan Cruz Viotti <jv@jviotti.com>
Signed-off-by: Juan Cruz Viotti <jv@jviotti.com>
Signed-off-by: Juan Cruz Viotti <jv@jviotti.com>
Signed-off-by: Juan Cruz Viotti <jv@jviotti.com>
Signed-off-by: Juan Cruz Viotti <jv@jviotti.com>
Signed-off-by: Juan Cruz Viotti <jv@jviotti.com>
@jviotti jviotti merged commit d76c611 into main Mar 31, 2026
13 of 14 checks passed
@jviotti jviotti deleted the core-cpp23 branch March 31, 2026 14:21
tmeijn pushed a commit to tmeijn/dotfiles that referenced this pull request Apr 2, 2026
This MR contains the following updates:

| Package | Update | Change |
|---|---|---|
| [sourcemeta/jsonschema](https://github.com/sourcemeta/jsonschema) | minor | `v14.14.2` → `v14.17.1` |

MR created with the help of [el-capitano/tools/renovate-bot](https://gitlab.com/el-capitano/tools/renovate-bot).

**Proposed changes to behavior should be submitted there as MRs.**

---

### Release Notes

<details>
<summary>sourcemeta/jsonschema (sourcemeta/jsonschema)</summary>

### [`v14.17.1`](https://github.com/sourcemeta/jsonschema/releases/tag/v14.17.1)

[Compare Source](sourcemeta/jsonschema@v14.17.0...v14.17.1)

#### What's Changed

- Statically link the C++ standard library on the Linux binaries for extra distro compatibility by [@&#8203;jviotti](https://github.com/jviotti) in [#&#8203;701](sourcemeta/jsonschema#701)
- Fix a case of rounding error on `multipleOf` with negative exponents of 10 by [@&#8203;jviotti](https://github.com/jviotti) in [#&#8203;703](sourcemeta/jsonschema#703)

**Full Changelog**: <sourcemeta/jsonschema@v14.17.0...v14.17.1>

### [`v14.17.0`](https://github.com/sourcemeta/jsonschema/releases/tag/v14.17.0)

[Compare Source](sourcemeta/jsonschema@v14.16.2...v14.17.0)

#### What's Changed

- New linter rules: `forbid_empty_enum` and `invalid_external_ref` by [@&#8203;jviotti](https://github.com/jviotti) in [#&#8203;695](sourcemeta/jsonschema#695)

**Full Changelog**: <sourcemeta/jsonschema@v14.16.2...v14.17.0>

### [`v14.16.2`](https://github.com/sourcemeta/jsonschema/releases/tag/v14.16.2)

[Compare Source](sourcemeta/jsonschema@v14.16.1...v14.16.2)

#### What's Changed

- Fix a few subtle URI unescaping RFC compliant issues by [@&#8203;jviotti](https://github.com/jviotti) in [#&#8203;693](sourcemeta/jsonschema#693)
- Fix `lint --fix` affecting rounding of some real numbers by [@&#8203;jviotti](https://github.com/jviotti) in [#&#8203;694](sourcemeta/jsonschema#694)

**Full Changelog**: <sourcemeta/jsonschema@v14.16.1...v14.16.2>

### [`v14.16.1`](https://github.com/sourcemeta/jsonschema/releases/tag/v14.16.1)

[Compare Source](sourcemeta/jsonschema@v14.16.0...v14.16.1)

#### What's Changed

- Avoid tracking instance positions on `--fast` mode by [@&#8203;jviotti](https://github.com/jviotti) in [#&#8203;689](sourcemeta/jsonschema#689)
- Speed up parsing of big instances by orders of magnitude by [@&#8203;jviotti](https://github.com/jviotti) in [#&#8203;691](sourcemeta/jsonschema#691) and [#&#8203;688](sourcemeta/jsonschema#688)

**Full Changelog**: <sourcemeta/jsonschema@v14.16.0...v14.16.1>

### [`v14.16.0`](https://github.com/sourcemeta/jsonschema/releases/tag/v14.16.0)

[Compare Source](sourcemeta/jsonschema@v14.15.0...v14.16.0)

#### What's Changed

- Add linter rules to catch `enum` + `const` by [@&#8203;jviotti](https://github.com/jviotti) in [#&#8203;686](sourcemeta/jsonschema#686)
- Make it clear we don't support 2020-12 `format-assertion` yet by [@&#8203;jviotti](https://github.com/jviotti) in [#&#8203;687](sourcemeta/jsonschema#687)

**Full Changelog**: <sourcemeta/jsonschema@v14.15.0...v14.16.0>

### [`v14.15.0`](https://github.com/sourcemeta/jsonschema/releases/tag/v14.15.0)

[Compare Source](sourcemeta/jsonschema@v14.14.2...v14.15.0)

#### What's Changed

- Support standard input through `-` in all commands by [@&#8203;Vaibhav701161](https://github.com/Vaibhav701161) in [#&#8203;661](sourcemeta/jsonschema#661)

**Full Changelog**: <sourcemeta/jsonschema@v14.14.2...v14.15.0>

</details>

---

### Configuration

📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied.

♻ **Rebasing**: Whenever MR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 **Ignore**: Close this MR and you won't be reminded about this update again.

---

 - [ ] <!-- rebase-check -->If you want to rebase/retry this MR, check this box

---

This MR has been generated by [Renovate Bot](https://github.com/renovatebot/renovate).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiI0My45Mi4xIiwidXBkYXRlZEluVmVyIjoiNDMuMTAyLjIiLCJ0YXJnZXRCcmFuY2giOiJtYWluIiwibGFiZWxzIjpbIlJlbm92YXRlIEJvdCIsImF1dG9tYXRpb246Ym90LWF1dGhvcmVkIiwiZGVwZW5kZW5jeS10eXBlOjptaW5vciJdfQ==-->
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant