rustbuild: clarify comment on target array calculation
The comment touched, as originally written, only concerned itself with the `test` steps. However, since #38468 the `arr` variable actually has gained an indirect relationship with the `dist` steps too. The comment failed to convey the extra meaning, contributing to the misunderstanding which eventually lead to #38637. Fix that by moving the comment into the right place near the relevant condition, and properly documenting `arr`'s purpose.
This commit is contained in:
parent
9d3616f78d
commit
3991046d52
1 changed files with 3 additions and 2 deletions
|
@ -838,9 +838,10 @@ invalid rule dependency graph detected, was a rule added and maybe typo'd?
|
|||
} else {
|
||||
&self.build.config.target
|
||||
};
|
||||
// If --target was specified but --host wasn't specified, don't run
|
||||
// any host-only tests
|
||||
// Determine the actual targets participating in this rule.
|
||||
let arr = if rule.host {
|
||||
// If --target was specified but --host wasn't specified,
|
||||
// don't run any host-only tests
|
||||
if self.build.flags.target.len() > 0 &&
|
||||
self.build.flags.host.len() == 0 {
|
||||
&[]
|
||||
|
|
Loading…
Add table
Reference in a new issue