Skip to content

feat(libc): implement the std::__sce_v2 messages virtuals - #17296

Open
Danigamer05 wants to merge 30 commits into
boykopovar:mainfrom
Danigamer05:feat/libc-sce-v2-messages-20261108
Open

Danigamer05 wants to merge 30 commits into
boykopovar:mainfrom
Danigamer05:feat/libc-sce-v2-messages-20261108

Conversation

@Danigamer05

@Danigamer05 Danigamer05 commented Nov 8, 2026 •

Copy link
Copy Markdown
Contributor

What

Builds on #17277: this branch contains its commits, and through them #16975, #16949, #16944, #16924, #16919, #16560, #16516, #16214, #16178 and #15923, with current main. It needs none of their code, only their place in LocaleSupport.cpp, so it stacks to avoid conflicts. Until they merge, only the last commit is this PR's change.

Implement the three virtuals of std::__sce_v2::messages<char> and messages<wchar_t>, which _Makeloc builds and use_facet hands to callers that look up translated strings. Before this PR, each of their six slots threw NotImplemented_nid_no_patch. These slots are not exports, so this PR adds no NID.

The behavior comes from the libc.prx bundled with PPSA03671 v01.001.005 (J03848509, SHA-256 483961e086b8a1fffa8138b3c0badf798987fb5f35ec908d828946408be2d8a6), vtables 0x18C8C8 and 0x18CFD0:

  • do_open returns -1: the module has no message catalogs.
  • do_get returns a copy of the default string, built as the module's copy constructor builds it. A default of at most 15 char or 7 wchar_t units is copied with the whole 16-byte buffer it is read from; a longer one gets a capacity from its length, length | 15 or length | 7, and its units are copied with the one after them. The source buffer is chosen by the default's capacity, as the module does.
  • do_close does nothing.

The _Makeloc debt entry lists messages among the working facets.

Tested

Windows 11, MinGW GCC 15.2, Release, head on top of #17277. Not run on Linux or macOS, not run in a title.

  • New test guest_sce_v2_messages: do_open, do_close, and do_get with short, long and short-on-heap defaults for both character types, checking sizes, capacities, the copied inline buffer and the unit after a long default.
  • Differential harness against the module's own code, loaded and relocated, with the facets from each side's _Makeloc. Defaults of 0 to 4,400 units, inline or on the heap, with random bytes after the length and capacities that do not match the length. It compares the result, the returned string's size, capacity, inline buffer or heap contents, and the allocations each side makes: 900,000 calls over 3 seeds (about 396,000 heap defaults and 303,000 allocated results), 0 differences.
  • The libc tests built from this head, without the tests that drive the GPU, audio or controllers (150: every guest_sce_v2_*, locale, string and public_headers test): all pass.
  • Negative control: 5 single-change mutations. The harness catches all 5 and the final test catches all 5; the first test run missed the unit copied after a long default, so the test was strengthened and that mutation rerun.
  • check_conventions, git diff --check: clean. Merges cleanly with main. pr_overlap reports no open PR with the same functions or conflicting code; it could not compare 45 PRs that conflict with main on shared files, and of the 4 that touch LocaleSupport.cpp (feat(libc): add std::__sce_v2::_Random_device, _Fiopen and setw #9526, feat(libc): wire the codecvt<wchar_t,char> facet vtable #11172, feat(libc): export the money_put facet vtable as data #12518, feat(libc): export the wide time_put facet vtable as data #12704) none adds these virtuals.

Checklist

  • Based on current main; no other open PR implements the same functions
  • One topic per PR; follow-ups go in a new PR
  • No comments in code except technical debt
  • Unimplemented paths throw (NotImplemented_nid_no_patch); silent stubs are listed under Silent stubs in their library's technical debt file
  • No notes, investigation .md files or images added to the repository (attach them to this PR)
  • New third-party code is a submodule built from source
  • Generic behaviour, not specific to one title
  • Depends on: feat(libc): implement the std::__sce_v2 collate and moneypunct virtuals #17277
  • Fixes: none
  • Unblocks: none
  • GPUs tested: n/a
  • AI-assisted: yes

Danigamer05 and others added 20 commits November 5, 2026 21:33
…irtuals for char

The facets built by _Makeloc threw NotImplemented from every virtual
except the lifecycle slots. The char ctype, numpunct and codecvt facets
now answer as the console's libc.prx does.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…irtuals for wchar_t

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Main removed GuestStringInlineCapacity, GuestStringCapacityMask and
GuestStringLargeAllocation from LocaleSupport.cpp, so the versioned
facets' strings use GuestLocale::StringInlineCapacity,
GuestLocale::StringCapacityMask and GuestStringStorage::Deallocate.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…egers, bool and pointers

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Main removed GuestStringInlineCapacity and GuestStringCapacityMask from
LocaleSupport.cpp, so AssignSceV2String uses
GuestLocale::StringInlineCapacity and GuestLocale::StringCapacityMask.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Main removed GuestStringInlineCapacity and GuestStringLargeAllocation
from LocaleSupport.cpp, so TakeSceV2String tests
GuestLocale::StringInlineCapacity and frees through
GuestStringStorage::Deallocate.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…sce-v2-num-put-wide-20261107

Brings in current main through boykopovar#16516. The templated TakeSceV2String
frees through GuestStringStorage::Deallocate, since main removed
GuestStringLargeAllocation from LocaleSupport.cpp.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…integers, bool and pointers

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ating point

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…sce-v2-num-get-wide-floating-20261108

# Conflicts:
#	docs/dev/debt/libc.md
…floating point

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Implement do_compare, do_transform and do_hash of collate<char> and
collate<wchar_t>, and the nine virtuals of moneypunct<char, Intl> and
moneypunct<wchar_t, Intl>, following the libc.prx of PPSA03671.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Implement do_open, do_get and do_close of messages<char> and
messages<wchar_t>, following the libc.prx of PPSA03671: no catalog
opens, and do_get returns a copy of the default string.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@github-actions

github-actions Bot commented Nov 8, 2026 •

Copy link
Copy Markdown

Some comparisons could not be completed because a pull request conflicts with the base branch. Review these shared files manually before concluding that there is no overlap.

Pull request Shared files not compared
PR 7715 core/libs/prx/libc/CMakeLists.txt
docs/dev/debt/libc.md
PR 8965 core/libs/prx/libc/CMakeLists.txt
docs/dev/debt/libc.md
PR 9087 docs/dev/debt/libc.md
PR 11661 docs/dev/debt/libc.md
PR 11689 docs/dev/debt/libc.md
PR 11698 docs/dev/debt/libc.md
PR 12682 core/libs/prx/libc/CMakeLists.txt
PR 12688 core/libs/prx/libc/CMakeLists.txt
PR 12700 core/libs/prx/libc/CMakeLists.txt
PR 12717 core/libs/prx/libc/CMakeLists.txt
PR 12849 core/libs/prx/libc/CMakeLists.txt
docs/dev/debt/libc.md
PR 12965 core/libs/prx/libc/CMakeLists.txt
PR 15973 docs/dev/debt/libc.md
PR 17746 core/libs/prx/libc/include/GuestLocale.hpp
core/libs/prx/libc/src/LocaleSupport.cpp
PR 23395 core/libs/prx/libc/CMakeLists.txt
PR 24907 core/libs/prx/libc/include/GuestLocale.hpp
core/libs/prx/libc/src/LocaleSupport.cpp
PR 25573 core/libs/prx/libc/include/GuestLocale.hpp
core/libs/prx/libc/src/LocaleSupport.cpp
PR 28051 core/libs/prx/libc/CMakeLists.txt
PR 28565 core/libs/prx/libc/CMakeLists.txt
PR 28568 core/libs/prx/libc/include/GuestLocale.hpp
core/libs/prx/libc/src/LocaleSupport.cpp
PR 28709 core/libs/prx/libc/CMakeLists.txt
core/libs/prx/libc/include/GuestLocale.hpp
PR 28808 core/libs/prx/libc/CMakeLists.txt

@JJenkx

JJenkx commented Nov 8, 2026

Copy link
Copy Markdown
Contributor

Windows check of head 4860ac9cf3, merged onto main ef9ab2ea44 (c4bd5ee985, clean merge).

Setup: Windows 11 Enterprise 22621, WinLibs GCC 15.2 UCRT, Release. The hosted Windows check does not run these tests on pull requests.

  • guest_sce_v2_char_facet_virtuals, guest_sce_v2_codecvt_wide, guest_sce_v2_collate_moneypunct, guest_sce_v2_facet_ids, guest_sce_v2_makeloc, guest_sce_v2_messages, guest_sce_v2_num_get_char, guest_sce_v2_num_get_wide, guest_sce_v2_num_put_char, guest_sce_v2_num_put_wide pass in 3 of 3 runs, none skipped.

AI-assisted: yes.

@PrivacyOnion PrivacyOnion left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Verified on Linux (Ubuntu 24.04, GCC 13.3, Ninja, Release) against 4860ac9cf3:

  • Conventions: tools/check_conventions.py passed; git diff --check clean.
  • Build: guest_sce_v2_char_facet_virtuals_tests, guest_sce_v2_codecvt_wide_tests, guest_sce_v2_collate_moneypunct_tests, guest_sce_v2_facet_ids_tests, guest_sce_v2_makeloc_tests, guest_sce_v2_messages_tests, guest_sce_v2_num_get_char_tests, guest_sce_v2_num_get_wide_tests, guest_sce_v2_num_put_char_tests, guest_sce_v2_num_put_wide_tests failed to build.
    core/libs/prx/libc/src/LocaleSupport.cpp:2977:49: error: no matching function for call to ‘min(const int64_t&, long long int)’
    
  • Minor: please drop the Generated with footer from the description; the AI-assisted checkbox can stay.

Requesting changes for the points above.

Danigamer05 and others added 2 commits November 12, 2026 22:56
…61108

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

@PrivacyOnion PrivacyOnion left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Verified on Linux (Ubuntu 24.04, GCC 13.3, Ninja, Release) against 49b19761b0:

  • Conventions: tools/check_conventions.py passed; git diff --check clean.
  • Build: guest_sce_v2_char_facet_virtuals_tests, guest_sce_v2_codecvt_wide_tests, guest_sce_v2_collate_moneypunct_tests, guest_sce_v2_facet_ids_tests, guest_sce_v2_makeloc_tests, guest_sce_v2_messages_tests, guest_sce_v2_num_get_char_tests, guest_sce_v2_num_get_wide_tests, guest_sce_v2_num_put_char_tests, guest_sce_v2_num_put_wide_tests failed to build.
    core/libs/prx/libc/src/LocaleSupport.cpp:2994:49: error: no matching function for call to ‘min(const int64_t&, long long int)’
    
  • Minor: please drop the Generated with footer from the description; the AI-assisted checkbox can stay.

Requesting changes for the points above.

Danigamer05 and others added 2 commits November 13, 2026 07:57
std::int64_t is long on Linux x86-64 and std::llabs returns long long,
so std::min could not deduce a single type and LocaleSupport.cpp did not
build there. Name std::int64_t explicitly.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@Danigamer05

Copy link
Copy Markdown
Contributor Author

@PrivacyOnion Thanks for the review. The build error came from 90d09a0 in #16944. It is fixed there in 942b87f (std::min<std::int64_t>), and the fix is merged into this branch, so the head is now faf0174.

On Ubuntu 24.04 with GCC 13.3, g++ -fsyntax-only with the project's flags now passes on LocaleSupport.cpp and on the GuestSceV2* tests. This is a syntax check, not a full build. On Windows the 27 guest_sce_v2_* tests pass. I removed the Generated with footer from the description.

AI-assisted: yes

@PrivacyOnion PrivacyOnion left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Verified on Linux (Ubuntu 24.04, GCC 13.3, Ninja, Release) against faf01748c3:

  • Conventions: tools/check_conventions.py passed; git diff --check clean.
  • Build: guest_sce_v2_char_facet_virtuals_tests, guest_sce_v2_codecvt_wide_tests, guest_sce_v2_collate_moneypunct_tests, guest_sce_v2_facet_ids_tests, guest_sce_v2_makeloc_tests, guest_sce_v2_messages_tests, guest_sce_v2_num_get_char_tests, guest_sce_v2_num_get_wide_tests, guest_sce_v2_num_put_char_tests, guest_sce_v2_num_put_wide_tests built cleanly.
  • CTest (guest_sce_v2_makeloc, guest_sce_v2_char_facet_virtuals, guest_sce_v2_num_put_char, guest_sce_v2_num_put_wide, guest_sce_v2_codecvt_wide, guest_sce_v2_collate_moneypunct, guest_sce_v2_messages, guest_sce_v2_num_get_char, guest_sce_v2_num_get_wide, guest_sce_v2_facet_ids):
    1/10 Test  #847: guest_sce_v2_char_facet_virtuals ...   Passed    0.02 sec
    2/10 Test  #846: guest_sce_v2_makeloc ...............   Passed    0.03 sec
    3/10 Test  #848: guest_sce_v2_num_put_char ..........   Passed    0.02 sec
    4/10 Test  #849: guest_sce_v2_num_put_wide ..........   Passed    0.03 sec
    5/10 Test  #850: guest_sce_v2_codecvt_wide ..........   Passed    0.02 sec
    6/10 Test  #851: guest_sce_v2_collate_moneypunct ....   Passed    0.02 sec
    7/10 Test  #852: guest_sce_v2_messages ..............   Passed    0.02 sec
    8/10 Test  #853: guest_sce_v2_num_get_char ..........   Passed    0.03 sec
    9/10 Test  #854: guest_sce_v2_num_get_wide ..........   Passed    0.03 sec
    10/10 Test #1133: guest_sce_v2_facet_ids .............   Passed    0.02 sec
    100% tests passed, 0 tests failed out of 10
    
  • Negative control: with core/libs/prx/libc/include/Api.hpp, core/libs/prx/libc/include/GuestLocale.hpp, core/libs/prx/libc/src/LocaleSupport.cpp reverted to main, the new tests do not build/link without the change; restoring it makes them build and pass.
  • Code reading:
    • Verified that the previously reported GCC 13.3 build failure (std::min(const int64_t&, long long int)) in core/libs/prx/libc/src/LocaleSupport.cpp has been resolved and all 10 guest_sce_v2_* test targets build and pass on Linux x86_64.
    • Checked std::__sce_v2::messages<char> and messages<wchar_t> virtual functions (do_open, do_get, do_close) in core/libs/prx/libc/src/LocaleSupport.cpp for SSO threshold logic (15 char / 7 wchar_t), dynamic capacity calculation (length | 15 / length | 7), and null-terminator copying.
    • Verified that guest_sce_v2_messages_tests in core/libs/prx/libc/CMakeLists.txt and GuestSceV2Messages.cpp exercises do_open, do_get (both SSO and heap-allocated strings), and do_close for narrow and wide messages facets, and fails when the implementation is reverted.
    • Confirmed compliance with AGENTS.md rules (tools/check_conventions.py passed, git diff --check clean, and technical debt updated in docs/dev/debt/libc.md).
    • Verified cross-platform LP64 (Linux) and LLP64 (Windows) compatibility across the stacked SceV2 locale changes and test targets.

Looks Good To Me

@github-actions github-actions Bot added the needs rebase Conflicts with main, rebase needed label Nov 17, 2026

@MarcZX10 MarcZX10 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Reviewed messages facets — no blocking findings

Nothing blocks this; the points below are optional.

What I ran

  • Head reviewed: bf56220c779453962d012f8191192f654831cd01, base main. The change is the stacked branch as shown in diff.patch; the messages virtuals are the last commit of this PR.
  • Read the title and body, commits.md, manifest.json, files.json and diff.patch. Read the messages virtuals and their registration in core/libs/prx/libc/src/LocaleSupport.cpp, the messages test core/libs/tests/GuestSceV2Messages.cpp, the messages block of core/libs/prx/libc/CMakeLists.txt, and the _Makeloc entries of docs/dev/debt/libc.md.
  • Repository searches at the head with repo_read.py:
python3 repo_read.py search AllocateStringStorage
python3 repo_read.py search _Facet_Register
  • No build and no test run on my side. The test results in the description are the author's.

Results

Check Result Note
Messages code and test read passed Read in full
Rest of the diff read not run Read in part; see Not verified
Test build and run not run Author-reported only
No comments in added code passed Grep found none
_Makeloc debt entry passed Lists messages as working

Findings

Blocking

None.

Non-blocking

  • core/libs/tests/GuestSceV2Messages.cpp:90 — long_ comes from do_get with a 40-unit default, so its buffer is allocated through AllocateStringStorage and never freed. core/libs/tests/GuestSceV2Messages.cpp:95 (copiedEnd) leaks the same way. The process exits right after, so this does not affect the result, but the test allocates two heap strings it never releases.

Not verified

  • The module-derived behaviour: the do_get copy rule, the 0x20 messages category, the vtable addresses and the SHA-256 of libc.prx. I have no access to the module binary here.
  • Build and test results: the Windows 11 / MinGW GCC 15.2 run and the 150-test libc run are the author's report. I did not run them.
  • Not read: most of core/libs/prx/libc/src/LocaleSupport.cpp (num_put, num_get, codecvt, collate, moneypunct, money_get/put and time_get/put implementations and their registration), and the hunks of core/libs/prx/libc/include/GuestLocale.hpp beyond the SceV2IosBase change.
  • Not read: core/libs/tests/GuestSceV2CharFacetVirtuals.cpp, GuestSceV2CodecvtWide.cpp, GuestSceV2CollateMoneypunct.cpp, GuestSceV2Makeloc.cpp, GuestSceV2NumGetChar.cpp, GuestSceV2NumGetWide.cpp, GuestSceV2NumPutChar.cpp, GuestSceV2NumPutWide.cpp, and core/libs/prx/libc/include/Api.hpp beyond its added declarations.
  • The messages test target in core/libs/prx/libc/CMakeLists.txt (new line 502) does not list GuestSceV2Exceptions.S, which the _Makeloc test target does. I did not check whether this test needs it.
  • The _Facet_Register change (LocaleSupport.cpp, around the _Facet_Register definition) now prepends a node, and the matching debt sentence was removed. I saw the change in the diff but did not read the surrounding code.

To get this to a good state

Nothing is required. The non-blocking point above is optional.

@PrivacyOnion PrivacyOnion left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Verified on Linux (Ubuntu 24.04, GCC 13.3, Ninja, Release) against a38d4007e8:

  • Conventions: tools/check_conventions.py passed.
  • Build: guest_sce_v2_char_facet_virtuals_tests, guest_sce_v2_codecvt_wide_tests, guest_sce_v2_collate_moneypunct_tests, guest_sce_v2_messages_tests, guest_sce_v2_num_get_char_tests, guest_sce_v2_num_get_wide_tests, guest_sce_v2_num_put_char_tests, guest_sce_v2_num_put_wide_tests built cleanly.
  • CTest (guest_sce_v2_char_facet_virtuals, guest_sce_v2_num_put_char, guest_sce_v2_num_put_wide, guest_sce_v2_codecvt_wide, guest_sce_v2_collate_moneypunct, guest_sce_v2_messages, guest_sce_v2_num_get_char, guest_sce_v2_num_get_wide):
    1/8 Test #1132: guest_sce_v2_char_facet_virtuals ...   Passed    0.12 sec
    2/8 Test #1133: guest_sce_v2_num_put_char ..........   Passed    0.13 sec
    3/8 Test #1134: guest_sce_v2_num_put_wide ..........   Passed    0.06 sec
    4/8 Test #1135: guest_sce_v2_codecvt_wide ..........   Passed    0.04 sec
    5/8 Test #1136: guest_sce_v2_collate_moneypunct ....   Passed    0.03 sec
    6/8 Test #1137: guest_sce_v2_messages ..............   Passed    0.03 sec
    7/8 Test #1138: guest_sce_v2_num_get_char ..........   Passed    0.04 sec
    8/8 Test #1139: guest_sce_v2_num_get_wide ..........   Passed    0.03 sec
    100% tests passed, 0 tests failed out of 8
    
  • Negative control: with core/libs/prx/libc/include/GuestLocale.hpp, core/libs/prx/libc/src/LocaleSupport.cpp reverted to main, the new tests do not build/link without the change; restoring it makes them build and pass.
  • Code reading:
    • Verified do_open, do_get, and do_close implementations for both narrow char and wide char16_t std::__sce_v2::messages facets in core/libs/prx/libc/src/LocaleSupport.cpp against PPSA03671 v01.001.005 libc.prx specifications.
    • Checked string copying mechanics in SceV2BasicString, ReserveSceV2String, and AssignSceV2String/AssignSceV2WideString, ensuring correct small string optimization thresholds (InlineCapacity: 15 for char, 7 for char16_t) and null termination.
    • Audited memory layout, ABI calling conventions (APS5_VABI), and vtable slot alignment in SceV2MessagesCharVtable and SceV2MessagesWideVtable against GuestLocale::FacetVtable.
    • Verified cross-platform 64-bit cleanliness (LP64 Linux vs LLP64 Windows) in size/capacity representation and pointer arithmetic.
    • Confirmed AGENTS.md compliance, including lack of unauthorized code comments, proper technical debt accounting in docs/dev/debt/libc.md, and test integration in core/libs/prx/libc/CMakeLists.txt.

Looks Good To Me

@MarcZX10 MarcZX10 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Reviewed — comments

The messages facet implementation appears consistent with the described behavior, but the full change is not verified because several changed files were not reviewed.

What I ran

Reviewed head a38d4007e813743a7cc8a0d221370f7536cc52fa using the pinned repo_read.py reader. I read the prepared description, commit list, diff, manifest, and review-folder README; I did not run tests or other commands.

Results

Check Result Note
Messages implementation passed Inspected implementation and focused test
Test execution not run No checks run during this review
Full change review not run Several changed files were not read

Findings

Blocking

None verified in the inspected messages implementation.

Non-blocking

None.

Not verified

The reviewed material included core/libs/prx/libc/CMakeLists.txt, core/libs/prx/libc/include/GuestLocale.hpp, core/libs/prx/libc/src/LocaleSupport.cpp, core/libs/tests/GuestSceV2Messages.cpp, and docs/dev/debt/libc.md (the relevant implementation and test ranges, plus the prepared diff). The changed files core/libs/tests/GuestSceV2CharFacetVirtuals.cpp, core/libs/tests/GuestSceV2CodecvtWide.cpp, core/libs/tests/GuestSceV2CollateMoneypunct.cpp, core/libs/tests/GuestSceV2NumGetChar.cpp, core/libs/tests/GuestSceV2NumGetWide.cpp, core/libs/tests/GuestSceV2NumPutChar.cpp, and core/libs/tests/GuestSceV2NumPutWide.cpp were not read. Their behavior and tests are not verified. No tests were run in this review; platform and in-title behavior were not confirmed.

To get this to a good state

Nothing is required for the inspected messages implementation. The unreviewed changed files need review before a formal approval is justified.

Danigamer05 and others added 2 commits November 20, 2026 18:00
A review asked whether a field whose first 768 or more digits are zeros
could reach the lost-digit rounding with no kept digit, and bump the
leading zero or the decimal point. It cannot: leading zeros in the
integer part are not counted, and leading fraction zeros only lower the
power, so the first nonzero digit is always kept. Pin that down with 800
integer zeros, 769 fraction zeros before a 1 scaled back by e770, and
both together. Counting leading zeros as significant fails two of them.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

@MarcZX10 MarcZX10 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Reviewed — no blocking findings

The messages virtuals match the stated behavior in the inspected source; one test fixture may read beyond its backing string allocation.

What I ran

Inspected the prepared diff and source at head 07fda02256d1f751de8687e835649e9cc3740df6; no build or tests were run.

Results

Check Result Note
Diff and messages implementation passed Target behavior inspected
Build and tests not run No commands run
Full changed-file review not run Several changed files unread

Findings

Blocking

None.

Non-blocking

  • core/libs/tests/GuestSceV2Messages.cpp:98-104: the short-on-heap fixture points at a std::basic_string with only two characters but claims capacity 31. The implementation copies the full inline buffer for a short default, so this fixture can read beyond the string's allocated storage. Back it with a buffer sized to the claimed capacity before testing this case.

Not verified

Read review/description.md, review/commits.md, review/manifest.json, review/diff.patch, the complete GuestSceV2Messages.cpp, and the messages implementation in LocaleSupport.cpp. Did not read the other changed files, including the broader locale facet additions and tests; those changes are not reviewed here. Did not verify author-reported test results or run a negative control.

To get this to a good state

Nothing is required. The test-fixture point above is optional.

@ligmaSec ligmaSec left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Built the branch’s locale implementation and matching headers against the existing Linux runtime. The focused GuestSceV2Messages fixture passed.

AI-assisted: yes.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants