Skip to content

Commit

Permalink
print_target_features: Sort output
Browse files Browse the repository at this point in the history
I didn't find `crt-static` at first, because it was put at the bottom of
a large and otherwise sorted list.

Sort the lists before we print them.
  • Loading branch information
Enselic committed Jun 13, 2024
1 parent f158600 commit 52a16bb
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions compiler/rustc_codegen_llvm/src/llvm_util.rs
Original file line number Diff line number Diff line change
Expand Up @@ -398,7 +398,10 @@ fn print_target_features(out: &mut dyn PrintBackendInfo, sess: &Session, tm: &ll
"crt-static",
"Enables C Run-time Libraries to be statically linked",
)]);
rustc_target_features.sort();

llvm_target_features.retain(|(f, _d)| !known_llvm_target_features.contains(f));
llvm_target_features.sort();

let max_feature_len = llvm_target_features
.iter()
Expand Down

0 comments on commit 52a16bb

Please sign in to comment.