Repository navigation
feat(libc): export the C rune locale - #1781
Merged
Merged
Conversation
9 tasks done
babyhuey
force-pushed
the
feat/libc-rune-locale
branch
from
October 8, 2026 21:35
ef9a009 to
ba4d6ff
Compare
babyhuey
force-pushed
the
feat/libc-rune-locale
branch
from
October 9, 2026 08:32
ba4d6ff to
8aa4040
Compare
Contributor
|
Native Windows run, since no Windows results were posted. Setup: Windows 10 (19045), MinGW-w64 GCC 15.2.0 (WinLibs r7), Release. Head
No title was run. 🤖 Addressed by Claude Code |
babyhuey
force-pushed
the
feat/libc-rune-locale
branch
6 times, most recently
from
October 10, 2026 04:43
fa18211 to
7c876d4
Compare
babyhuey
force-pushed
the
feat/libc-rune-locale
branch
from
October 10, 2026 05:18
7c876d4 to
64be5f1
Compare
Collaborator
|
Checked the NIDs against aerolib, the |
SleglJan
pushed a commit
to SleglJan/AnyPS5
that referenced
this pull request
Oct 10, 2026
feat(libc): export the C rune locale
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Exports the FreeBSD C rune locale from libc:
_DefaultRuneLocale(lWGF8NHv880),_CurrentRuneLocale(chlN6g6UbGo) and__mb_sb_limit(fGYLBr2COwA). Titles built against FreeBSD<ctype.h>/<wctype.h>read_CurrentRuneLocale->__runetype[c]inline, bounded by__mb_sb_limit, and fall back to&_DefaultRuneLocale; they import these aslibSceLibcInternaldata._RuneLocalefollows FreeBSD 11include/runetype.h, checked withstatic_asserts:__runetypeat 64,__maplowerat 2112,__mapupperat 3136, ranges at 4160, 4224 bytes.lib/libc/locale/table.cfor all 256__runetype,__maplowerand__mapupperentries (compared offline against a parse of that file): ASCII classes, the digit value in the low byte of digits and hex letters, no class above 0x7f, magicRuneMagi, encodingNONE,__invalid_rune0xFFFD, empty_extranges._CurrentRuneLocalepoints at_DefaultRuneLocale, and__mb_sb_limitis 256, as in FreeBSDtable.candnone.cfor the C locale, the only localesetlocaleaccepts.Found with
tools/import_audit.pyon the catalog homebrew titles:_DefaultRuneLocaleis absent in 11 of 36 audited titles,_CurrentRuneLocaleand__mb_sb_limitin 9.Tested
Linux (Ubuntu 24.04, GCC 13, Release): new
guest_rune_localeand existingguest_localepass with--repeat until-fail:3. The test reads the export at raw FreeBSD offsets and checks every entry against the existingis*,tolowerandtoupperexports, the digit values, the header fields and__mb_sb_limit. It fails when the_CTYPE_Nbit is dropped from digits.check_conventions.pypasses. Windows: both files compile with MinGW-w64 GCC 13 (-Wall -Wextra -fsyntax-only); not run on Windows.import_audit.pywith the patched libraries, absent imports before → after: PPSA19111 66 → 63, PPSA59322 ccleste 50 → 47, PPSA68091 Ruffle 71 → 68, PPSA97510 74 → 71, PPSA98510 74 → 71, PPSA99002 74 → 71, PPSA99010 vkQuake 51 → 48, PPSA99764 80 → 77, PPSA99810 64 → 61. No title run.Checklist
main; no other open PR implements the same functionsNotImplemented_nid_no_patch); silent stubs are listed in TechnicalDebt.mdfiles or images added to the repository (attach them to this PR)