Skip to content

Commit

Permalink
Add unstable -Zdefault-hidden-visibility cmdline flag for rustc.
Browse files Browse the repository at this point in the history
The new flag has been described in the Major Change Proposal at
rust-lang/compiler-team#656
  • Loading branch information
anforowicz authored and GuillaumeGomez committed Feb 20, 2024
1 parent 0549b8d commit bc6826d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/allocator.rs
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ fn create_wrapper_function(
.collect();
let func = context.new_function(None, FunctionType::Exported, output.unwrap_or(void), &args, from_name, false);

if tcx.sess.target.options.default_hidden_visibility {
if tcx.sess.default_hidden_visibility() {
#[cfg(feature="master")]
func.add_attribute(FnAttribute::Visibility(gccjit::Visibility::Hidden));
}
Expand Down

0 comments on commit bc6826d

Please sign in to comment.