@@ -76,7 +76,7 @@ pub(crate) unsafe fn codegen(
7676 // __rust_alloc_error_handler_should_panic
7777 let name = OomStrategy :: SYMBOL ;
7878 let ll_g = llvm:: LLVMRustGetOrInsertGlobal ( llmod, name. as_ptr ( ) . cast ( ) , name. len ( ) , i8) ;
79- if tcx. sess . target . default_hidden_visibility {
79+ if tcx. sess . default_hidden_visibility ( ) {
8080 llvm:: LLVMRustSetVisibility ( ll_g, llvm:: Visibility :: Hidden ) ;
8181 }
8282 let val = tcx. sess . opts . unstable_opts . oom . should_panic ( ) ;
@@ -85,7 +85,7 @@ pub(crate) unsafe fn codegen(
8585
8686 let name = NO_ALLOC_SHIM_IS_UNSTABLE ;
8787 let ll_g = llvm:: LLVMRustGetOrInsertGlobal ( llmod, name. as_ptr ( ) . cast ( ) , name. len ( ) , i8) ;
88- if tcx. sess . target . default_hidden_visibility {
88+ if tcx. sess . default_hidden_visibility ( ) {
8989 llvm:: LLVMRustSetVisibility ( ll_g, llvm:: Visibility :: Hidden ) ;
9090 }
9191 let llval = llvm:: LLVMConstInt ( i8, 0 , False ) ;
@@ -130,7 +130,7 @@ fn create_wrapper_function(
130130 None
131131 } ;
132132
133- if tcx. sess . target . default_hidden_visibility {
133+ if tcx. sess . default_hidden_visibility ( ) {
134134 llvm:: LLVMRustSetVisibility ( llfn, llvm:: Visibility :: Hidden ) ;
135135 }
136136 if tcx. sess . must_emit_unwind_tables ( ) {
0 commit comments