feat(tvix/derivation): make input_sources a BTreeSet
These need to be sorted anyways, so let's use the correct data structure for it. Change-Id: I009c9989d7647dc1df716170f3680c981db6e4b2 Reviewed-on: https://cl.tvl.fyi/c/depot/+/7846 Autosubmit: flokli <flokli@flokli.de> Tested-by: BuildkiteCI Reviewed-by: tazjin <tazjin@tvl.su>
This commit is contained in:
parent
f6b4abac35
commit
95cad95b93
3 changed files with 5 additions and 14 deletions
|
|
@ -61,16 +61,8 @@ impl Derivation {
|
|||
}
|
||||
|
||||
// Validate all input_sources
|
||||
for (i, input_source) in self.input_sources.iter().enumerate() {
|
||||
for input_source in self.input_sources.iter() {
|
||||
StorePath::from_absolute_path(input_source)?;
|
||||
|
||||
if i > 0 && self.input_sources[i - 1] >= *input_source {
|
||||
bail!(
|
||||
"invalid input source order: {} < {}",
|
||||
input_source,
|
||||
self.input_sources[i - 1],
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
// validate platform
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue