Skip to content

size_t/ptrdiff_t transition part 4: libast regex and string sublibraries#950

Merged
McDutchie merged 12 commits intoksh93:devfrom
JohnoKing:thickfold-part-4-submission
Mar 27, 2026
Merged

size_t/ptrdiff_t transition part 4: libast regex and string sublibraries#950
McDutchie merged 12 commits intoksh93:devfrom
JohnoKing:thickfold-part-4-submission

Conversation

@JohnoKing
Copy link
Copy Markdown

@JohnoKing JohnoKing commented Mar 21, 2026

This is the fourth of the thickfold patch series, which enables ksh93 to operate within a 64-bit address space.

The parts of ksh93 affected by this commit are:

  • The libast string library.
  • The libast regex engine.
  • The libcmd paste builtin.
  • A few scattered bits of miscellaneous code using stresc (which now returns a ptrdiff_t result, a recent change after re-reviewing this patch prior to submission). Full changes for other libcmd builtins and pty are currently held for later parts of thickfold.

Change in the number of warnings on Linux when compiling with clang using -Wsign-compare -Wshorten-64-to-32 -Wsign-conversion -Wimplicit-int-conversion: 3,084 => 2,450 => 37 (progression from part 3 => part 4 => part 13)

(Part 13's warnings lowered in number due to minor fixes for that patch. It's of course currently held for a later PR.)

Progresses #592

This is the fourth of the thickfold patch series, which enables ksh93
to operate within a 64-bit address space.

The parts of ksh93 affected by this commit are:
- The libast string library.
- The libast regex engine.
- The libcmd paste builtin.
- A few scattered bits of miscellaneous code using stresc (which now
  returns a ptrdiff_t result). Full changes for other libcmd builtins
  and pty are currently held for later parts of thickfold.

Change in the number of warnings on Linux when compiling with clang using
-Wsign-compare -Wshorten-64-to-32 -Wsign-conversion -Wimplicit-int-conversion:
3,084 => 2,474 => 37 (progression from part 3 => part 4 => part 13)

Progresses ksh93#592
These changes are what were supposed to accompany the changes to
features/api, but the previous commit omitted them. (I did a
'git checkout thickfold-size_t -- src/lib/libast/features'
when I made that patch, which swept in the features/api file.)
@McDutchie McDutchie merged commit 69aa972 into ksh93:dev Mar 27, 2026
@JohnoKing JohnoKing deleted the thickfold-part-4-submission branch March 28, 2026 01:49
McDutchie pushed a commit that referenced this pull request Mar 28, 2026
This is the fourth of the thickfold patch series, which enables
ksh93 to operate within a 64-bit address space.

The parts affected by this commit are:
- The libast string library.
- The libast regex engine.
- The libcmd paste builtin.
- A few scattered bits of miscellaneous code using stresc (which
  now returns a ptrdiff_t result). Full changes for other libcmd
  builtins and pty are currently held for later parts of thickfold.

This commit also removes obsolete API versions of sfkeyprintf and
cmdarg.

Change in the number of warnings on Linux when compiling with clang
using -Wsign-compare -Wshorten-64-to-32 -Wsign-conversion
-Wimplicit-int-conversion: 3,084 => 2,474 => 37 (progression from
part 3 => part 4 => part 13)

Progresses #592
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.

2 participants