Pull request overview
This pull request attempts to make the codebase more portable by removing MacOS-incompatible inline assembly that was used for automatic command registration. The original implementation used GNU assembler directives (.pushsection, .popsection) and linker symbols to automatically collect command definitions into a table at link time. The new implementation introduces a simpler approach with a struct-based command table and a portable CMDLINE_FMT macro.
Changes:
- Replaced inline assembly-based command registration with portable C struct definitions
- Introduced
cmdline_entry struct to store command names and argument format strings
- Redefined CMDLINE_FMT macro to create static struct instances instead of assembly directives
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Originally posted by @Copilot in stephenrkell/vsfs#1 (review)
Pull request overview
This pull request attempts to make the codebase more portable by removing MacOS-incompatible inline assembly that was used for automatic command registration. The original implementation used GNU assembler directives (
.pushsection,.popsection) and linker symbols to automatically collect command definitions into a table at link time. The new implementation introduces a simpler approach with a struct-based command table and a portable CMDLINE_FMT macro.Changes:
cmdline_entrystruct to store command names and argument format strings💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Originally posted by @Copilot in stephenrkell/vsfs#1 (review)