-
Notifications
You must be signed in to change notification settings - Fork 12.8k
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
Use std::process::Command throughout compile-test #43798
Conversation
} | ||
|
||
fn compose_and_run(&self, | ||
ProcArgs{ args, prog }: ProcArgs, | ||
procenv: Vec<(String, String)> , | ||
mut command: Command, | ||
lib_path: &str, | ||
aux_path: Option<&str>, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wonder if maybe we could remove these arguments as well? It looks like not all tests need to pass this so we could have a helper which works with these variables and otherwise these aren't passed and the helper isn't called when not needed.
} | ||
|
||
fn compose_and_run(&self, | ||
ProcArgs{ args, prog }: ProcArgs, | ||
procenv: Vec<(String, String)> , | ||
mut command: Command, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One thing that may be worth testing is to take &mut Command
here instead of Command
. I'm not 100% sure which is more ergonomic, though!
}; | ||
|
||
// FIXME (#9639): This needs to handle non-utf8 paths |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great to see all these FIXME annotations removed!
This looks great to me, thanks! We can always delegate future refactorings to later PRs, this seems great enough to land in the meantime. |
Great. Happy to address the comments in the future. |
Oh so to be clear, @euclio mind trying to remove the |
Ah, sorry for the misunderstanding. I'll see if I can find the time this weekend. |
Which invocations actually need the library path munging? Just |
Oh I figured we'd just preserve the existing behavior which is that wherever |
☔ The latest upstream changes (presumably #43710) made this pull request unmergeable. Please resolve the merge conflicts. |
@alexcrichton Ok, do the commands ever need just |
In other words I'm wondering if there are any invocations that have a None aux path and still need their path munged to include an empty path. |
@euclio did you mean to close this? I don't think anything needs If this takes awhile to do though I don't want to block this! I'm fine landing this ahead of time if you'd like to take some more time to game out that change. |
Ah, whoops! Reopened. So, I think there's still a little question on how to handle the |
Ugh, looks like my rebase borked the branch. Will reopen shortly. |
Ok sounds good to me! Feel free to cc me on the new PR and I'll r+ |
Use std::process::Command throughout compile-test Resubmission of #43798. Fixes #43762. r? @alexcrichton
Fixes #43762.
r? @alexcrichton
Fixed up what didn't require a major refactor. I'd like to remove
ProcArgs
, but there's no way to get the current program name and args from aCommand
builder.compose_and_run
? I wonder if we could simplify that.expect
s in the output. Maybe it's worth threading the errors up through.