-
Notifications
You must be signed in to change notification settings - Fork 2.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Auto merge of #14000 - linyihai:fix-env-prefix, r=weihanglo
Fix: Skip deserialization of unrelated fields with overlapping name ### What does this PR try to resolve? Split from #13687 (comment) This fixes the overlap of environment variable names: > For example, when env_key is UNSTABLE_GITOXIDE_FETCH and field_key is UNSTABLE_GIT, the field shouldn't be added because `unstable.gitoxide.fetch` doesn't belong to `unstable.git` struct. ### How should we test and review this PR? Updates of test cases `struct_with_overlapping_inner_struct_and_defaults` can be used to compare changes before and after changes ### Additional information r? weihanglo and very appreciate your more optimized code
- Loading branch information
Showing
2 changed files
with
26 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters