plan9 port maintenance#1756
Conversation
|
This partly reverts the opaquing of JanetMarshalContext, so cc @iceghost. I'd like to find a way to fix compilation on plan9 without reverting that, since that seems to be an intentional change? |
|
I thought CI also covers Plan9. I'm not sure how to build for Plan9 yet, but I will take a look when I get home in like 9 hours. (it would be nice if you could include why it failed, since it is not apparent on the commit diff) |
|
Ah, downloading the ISO from https://9front.org is such a pain in the ass with all the rate limiting on their side. My downloads keep on timing out. I would recommend putting the compile errors here so people who don't have access to a Plan 9 installation could help review this pull request for you. Otherwise the change does not make sense to me. (Also I think you should fix your system clock...? The commits appear to be authored in 2023) |
There was a problem hiding this comment.
Pull request overview
This PR focuses on Plan 9 port maintenance by addressing regressions introduced after the initial Plan 9 port landed, primarily around process exiting semantics and file descriptor duplication during marshaling.
Changes:
- Moves
JanetMarshalContext’s struct definition into the public header and removes the duplicate private definition inmarsh.c. - Adjusts
(os/exit ... force)behavior on Plan 9 to useexits(...)instead of_Exit(...). - Fixes Plan 9-specific
dupusage when marshaling file handles.
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| src/include/janet.h | Exposes JanetMarshalContext layout in the public API. |
| src/core/os.c | Adds Plan 9-specific forced-exit path for (os/exit ...). |
| src/core/marsh.c | Removes the now-duplicated JanetMarshalContext struct definition. |
| src/core/io.c | Uses Plan 9’s 2-argument dup(old, new) form when duplicating FDs for marshaling. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| #ifdef JANET_PLAN9 | ||
| exits(nil); | ||
| #else | ||
| _Exit(status); | ||
| #endif |
|
@bakpakin am I allowed to ask what was exactly the compile error here that led to my change being reverted? |
|
@iceghost I don't think this reverted anything? |
Fixes a few regressions since the port initially landed