fix(libkernel): return after NotImplemented in Windows shm_unlink #4270

Merged
ErenYeager1836 merged 1 commit from upstream-pr/4270 into main 2026-10-12 10:46:32 +00:00
ErenYeager1836 commented 2026-10-12 03:39:58 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by ErenYeager1836 on 2026-10-12T03:39:58Z.


What

Adds return 0; after NotImplemented_nid_no_patch("shm_unlink of a named object")
in the #ifdef _WIN32 branch of shm_unlink_nid_postfix, silencing the
-Wreturn-type warning on Windows. No behavior change — NotImplemented_nid_no_patch
always throws, so the return is unreachable. Follows the pattern used throughout the
codebase (libc/Export.cpp, DirectMemory/Export.cpp, Equeue.cpp, etc.) and mirrors
the APS5_DUMMY_FUN macro.

Tested

Windows. Rebuilt libkernel — SharedMemory.cpp no longer emits the -Wreturn-type
warning. Existing tests pass.

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)
  • No notes or investigation files added to the repository
  • New third-party code is a submodule built from source

Depends on: none
AI-assisted: yes

<!-- greyfinch-sync:boykopovar/AnyPS5:issue:4824633384 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/4270). Originally posted by [ErenYeager1836](https://github.com/ErenYeager1836) on 2026-10-12T03:39:58Z. --- ### What Adds `return 0;` after `NotImplemented_nid_no_patch("shm_unlink of a named object")` in the `#ifdef _WIN32` branch of `shm_unlink_nid_postfix`, silencing the `-Wreturn-type` warning on Windows. No behavior change — `NotImplemented_nid_no_patch` always throws, so the return is unreachable. Follows the pattern used throughout the codebase (libc/Export.cpp, DirectMemory/Export.cpp, Equeue.cpp, etc.) and mirrors the APS5_DUMMY_FUN macro. ### Tested Windows. Rebuilt `libkernel` — `SharedMemory.cpp` no longer emits the `-Wreturn-type` warning. Existing tests pass. ### Checklist - [x] Based on current `main`; no other open PR implements the same functions - [x] One topic per PR; follow-ups go in a new PR - [x] No comments in code except technical debt - [x] Unimplemented paths throw (`NotImplemented_nid_no_patch`) - [x] No notes or investigation files added to the repository - [x] New third-party code is a submodule built from source Depends on: none AI-assisted: yes
Sign in to join this conversation.
No reviewers
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
boykopovar/AnyPS5!4270
No description provided.