feat(libSceLibcInternal): construct the wide num_put facet #24884
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/24884"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from boykopovar/AnyPS5. Originally posted by 0x70776c on 2026-11-21T09:04:35Z.
What
Implements
num_put<wchar_t>::_Getcat(_ZNSt7num_putIwSt19ostreambuf_iteratorIwSt11char_traitsIwEEE7_GetcatEPPKNSt6locale5facetEPKS5_, NID6iDi6e2e4x8) andnum_put<wchar_t>::num_put(const _Locinfo&, size_t)(_ZNSt7num_putIwSt19ostreambuf_iteratorIwSt11char_traitsIwEEEC2ERKSt8_Locinfom, NID0Pd-K5jGcgM) in NumPutField.cpp, updates declarations in InventoryExports6.hpp, removes their stubs from InventoryExports6.cpp, and updates technical debt via feat-libcinternal-wide-num-put-ctor.md.Constructed facets install a local
WideNumPutVtablewith realdestroy/delete/retain/releasereference-counting slots while forwarding all eightdo_putslots to the existing throwing exports (soErr.cppstays untouched).Tested
Fedora Linux 43 (
7.3.3-100.fc43.x86_64), GCC15.3.1, Release build (BUILD_TESTING=ON):CheckWideNumPutConstruction()in GuestLibcInternalFacetPut.cpp (signaturestatic_assert, constructor null guards,_Getcatnumeric category 4, existing vs empty slot construction, andretain/release/deleteObjectlifecycle).ctest --test-dir build -R '^(guest_libc_internal_facet_put|public_headers)$' -V: 2/2 passed.python3 tools/check_conventions.py --base origin/main: All conventions checks passed.python3 tools/debt_fold.py --check: passed.python3 tools/pr_overlap.py:open: noneon both symbols.Checklist
main; no other open PR implements the same functionsNotImplemented_nid_no_patch); silent stubs are listed under Silent stubs in their library's technical debt file.mdfiles or images added to the repository (attach them to this PR)Imported from boykopovar/AnyPS5. Originally posted by PrivacyOnion on 2026-11-21T09:05:56Z.
Review: APPROVED
Verified on Linux (Ubuntu 24.04, GCC 13.3, Ninja, Release) against
d634d762b5:tools/check_conventions.pypassed.guest_libc_internal_facet_put_testsbuilt cleanly.guest_libc_internal_facet_put):core/libs/prx/libSceLibcInternal/InventoryExports6.cpp,core/libs/prx/libSceLibcInternal/NumPutField.cpp,core/libs/prx/libSceLibcInternal/include/InventoryExports6.hppreverted tomain, the new tests do not build/link without the change; restoring it makes them build and pass.Looks Good To Me
Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-11-21T09:24:32Z.
Review: CHANGES_REQUESTED
Reviewed — changes requested
Changes are required before merge: make
_Getcatclean up its allocation if facet initialization throws.What I ran
Reviewed head
d634d762b54918b6a2696bccdb5520dd10a93224. No commands or tests were run; the build and checks described in the PR are author-reported.Results
Findings
Blocking
core/libs/prx/libSceLibcInternal/NumPutField.cpp:145—_Getcatallocates the facet, then calls the constructor before storing it in*facet. If the constructor throws (for example, if initialization later rejects the locale info), the allocation is leaked. Use a scope guard like the existing widetime_get::_Getcatimplementation so the allocation is freed on exceptions.Non-blocking
None.
Not verified
libSceLibcInternal.sprxwere not verified; the debt note also records this limitation.NumPutField.cpp,InventoryExports6.hpp,GuestLocale.hpp,LocaleSupport.cpp,TimeGetFields.cpp,CodecvtChar.cpp,GuestLibcInternalFacetPut.cpp,description.md,commits.md,manifest.json, anddiff.patch. All changed files listed inmanifest.jsonwere included; no changed file was excluded by rule.To get this to a good state
_Getcatallocation, then rerun the reported build, tests, and checks on the updated head.Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-11-21T09:30:53Z.
Review: APPROVED
Reviewed — looks good
Nothing blocks this change; the implementation and its targeted tests support merging.
What I ran
Reviewed head
750417f70e78b7b831722188c27f25d1699ff5c6using the prepared diff and the pinned repository reader. No commands or tests were run.Results
Findings
Blocking
None.
Non-blocking
None.
Not verified
The full texts of changed files listed as included in the manifest were not accessible through the reader, so those files were reviewed from the prepared diff only. The PR-reported build and tests were not run independently. Console behavior and compatibility with
libSceLibcInternal.sprxwere not verified; the PR records this as technical debt.To get this to a good state
Nothing is required.
Imported from boykopovar/AnyPS5. Originally posted by PrivacyOnion on 2026-11-21T09:32:06Z.
Review: APPROVED
Verified on Linux (Ubuntu 24.04, GCC 13.3, Ninja, Release) against
750417f70e:tools/check_conventions.pypassed.guest_libc_internal_facet_put_testsbuilt cleanly.guest_libc_internal_facet_put):core/libs/prx/libSceLibcInternal/InventoryExports6.cpp,core/libs/prx/libSceLibcInternal/NumPutField.cpp,core/libs/prx/libSceLibcInternal/include/InventoryExports6.hppreverted tomain, the new tests do not build/link without the change; restoring it makes them build and pass.Looks Good To Me
Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-11-22T15:28:25Z.
Review: COMMENTED
Reviewed — no blocking findings
The review folder and repository reader are not accessible through the available tools, so the change could not be inspected and a formal decision is not justified.
What I ran
Not run. The provided reader command could not be executed in this environment.
Results
Findings
Blocking
None verified.
Non-blocking
None.
Not verified
The description, commits, diff, manifest, changed files, and repository context were not read. Files read: none. Files reviewed: none.
To get this to a good state
Nothing is required.