Merged configuration lists have unexpected precedence ordering #12506
Labels
A-configuration
Area: cargo config files and env vars
A-rustflags
Area: rustflags
C-bug
Category: bug
S-needs-design
Status: Needs someone to work further on the design for the feature or fix. NOT YET accepted.
Problem
When merging TOML lists from configuration, the order does not follow the precedence order described in the documentation. The documentation does not explicitly specify the order for merging lists other than "Arrays will be joined together".
The docs state
I expected a merged list would be (or the reverse of this):
Instead, the order appears to be:
Steps
The following script illustrates the current situation.
If a non-list is used, the precedence of these values is:
Possible Solution(s)
Merge the lists with highest precedence first. The output of the above bash script should be:
An alternative would be to merge them with lowest precedence first.
Notes
No response
Version
The text was updated successfully, but these errors were encountered: