-
-
Notifications
You must be signed in to change notification settings - Fork 2.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
child_process + Build: rename exec to run + all related code #17623
Conversation
Personally, I don't think this should affect |
~~I do agree with comments, but disagree insofar as process spawn comments and help page in src/main.zig are not consistent, for example there is - // Here we ignore the CC environment variable and exec `cc` as a child process.
+ // Here we ignore the CC environment variable and run `cc` as a child process.
- \\ --test-no-exec Compiles test binary without running it
+ \\ --test-no-run Compiles test binary without running it
- \\ run Execute the output file, if it is an executable or test.
+ \\ run Run the output file, if it is an executable or test.
- fatal("the following command cannot be executed ({s} does not support spawning a child process):\n{s}", .{ @tagName(builtin.os.tag), cmd });
+ fatal("the following command cannot be run ({s} does not support spawning a child process):\n{s}", .{ @tagName(builtin.os.tag), cmd });
const repl_help =
\\Commands:
\\ update Detect changes to source files and update output files.
- \\ run Execute the output file, if it is an executable or test.
+ \\ run Run the output file, if it is an executable or test.
\\ update-and-run Perform an `update` followed by `run`.
\\ help Print this text
\\ exit Quit this repl
|
IMO confusion only arises when specifically dealing with a function named However, the verb |
08e249f
to
dc16bc4
Compare
Justification: exec, execv etc are unix concepts and portable version should be called differently. Do no touch non-Zig code. Adjust error names as well, if associated. Closes ziglang#5853.
Just my 2c, but I think I prefer the verb I.e., if a child process called a function That said, it's probably highly subjective and I'll gladly let the maintainers decide. |
Small updates for latest Zig updates: - ziglang/zig#17623 - ziglang/zig#17392 Tested with `zig build install` and `zig build test`
Justification: exec, execv etc are unix concepts and portable version should be called differently.
Do no touch non-Zig code. Adjust error names as well, if associated. Closes #5853.