Skip to content

Commit b5c9e24

Browse files
committed
Auto merge of rust-lang#77943 - est31:target_refactor, r=petrochenkov
No more target.target Two main changes of this PR: * Turn `target_pointer_width` into an integer and rename to `pointer_width`. The compiler only allowed three valid values for the width anyways. An integer is more natural for this value, and saves a few allocations and copies. * Remove the `rustc_session::config::Config` wrapper and replace it with its inner member `Target`. Aka. no more `target.target`. This makes life so much easier, but it also causes a ton of downstream breakage. Some changes of this PR were done using tooling. These tooling-made changes were isolated to their own commits to make review easier. It's best to review the PR commit-by-commit. Miri PR: rust-lang/miri#1583 I request p=10 bors priority because of the breakage.
2 parents 7f58716 + d683e3a commit b5c9e24

File tree

203 files changed

+406
-430
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

203 files changed

+406
-430
lines changed

compiler/rustc_ast_lowering/src/expr.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -985,7 +985,7 @@ impl<'hir> LoweringContext<'_, 'hir> {
985985
asm::InlineAsmReg::parse(
986986
sess.asm_arch?,
987987
|feature| sess.target_features.contains(&Symbol::intern(feature)),
988-
&sess.target.target,
988+
&sess.target,
989989
s,
990990
)
991991
.map_err(|e| {

compiler/rustc_ast_passes/src/ast_validation.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -796,7 +796,7 @@ impl<'a> Visitor<'a> for AstValidator<'a> {
796796

797797
fn visit_expr(&mut self, expr: &'a Expr) {
798798
match &expr.kind {
799-
ExprKind::LlvmInlineAsm(..) if !self.session.target.target.options.allow_asm => {
799+
ExprKind::LlvmInlineAsm(..) if !self.session.target.options.allow_asm => {
800800
struct_span_err!(
801801
self.session,
802802
expr.span,

compiler/rustc_builtin_macros/src/test_harness.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ struct TestCtxt<'a> {
3737
pub fn inject(sess: &Session, resolver: &mut dyn ResolverExpand, krate: &mut ast::Crate) {
3838
let span_diagnostic = sess.diagnostic();
3939
let panic_strategy = sess.panic_strategy();
40-
let platform_panic_strategy = sess.target.target.options.panic_strategy;
40+
let platform_panic_strategy = sess.target.options.panic_strategy;
4141

4242
// Check for #![reexport_test_harness_main = "some_name"] which gives the
4343
// main test function the name `some_name` without hygiene. This needs to be

compiler/rustc_codegen_llvm/src/allocator.rs

+6-6
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,10 @@ pub(crate) unsafe fn codegen(
1616
) {
1717
let llcx = &*mods.llcx;
1818
let llmod = mods.llmod();
19-
let usize = match &tcx.sess.target.target.target_pointer_width[..] {
20-
"16" => llvm::LLVMInt16TypeInContext(llcx),
21-
"32" => llvm::LLVMInt32TypeInContext(llcx),
22-
"64" => llvm::LLVMInt64TypeInContext(llcx),
19+
let usize = match tcx.sess.target.pointer_width {
20+
16 => llvm::LLVMInt16TypeInContext(llcx),
21+
32 => llvm::LLVMInt32TypeInContext(llcx),
22+
64 => llvm::LLVMInt64TypeInContext(llcx),
2323
tws => bug!("Unsupported target word size for int: {}", tws),
2424
};
2525
let i8 = llvm::LLVMInt8TypeInContext(llcx);
@@ -57,7 +57,7 @@ pub(crate) unsafe fn codegen(
5757
let name = format!("__rust_{}", method.name);
5858
let llfn = llvm::LLVMRustGetOrInsertFunction(llmod, name.as_ptr().cast(), name.len(), ty);
5959

60-
if tcx.sess.target.target.options.default_hidden_visibility {
60+
if tcx.sess.target.options.default_hidden_visibility {
6161
llvm::LLVMRustSetVisibility(llfn, llvm::Visibility::Hidden);
6262
}
6363
if tcx.sess.must_emit_unwind_tables() {
@@ -98,7 +98,7 @@ pub(crate) unsafe fn codegen(
9898
// -> ! DIFlagNoReturn
9999
llvm::Attribute::NoReturn.apply_llfn(llvm::AttributePlace::Function, llfn);
100100

101-
if tcx.sess.target.target.options.default_hidden_visibility {
101+
if tcx.sess.target.options.default_hidden_visibility {
102102
llvm::LLVMRustSetVisibility(llfn, llvm::Visibility::Hidden);
103103
}
104104
if tcx.sess.must_emit_unwind_tables() {

compiler/rustc_codegen_llvm/src/asm.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ impl AsmBuilderMethods<'tcx> for Builder<'a, 'll, 'tcx> {
6060

6161
// Default per-arch clobbers
6262
// Basically what clang does
63-
let arch_clobbers = match &self.sess().target.target.arch[..] {
63+
let arch_clobbers = match &self.sess().target.arch[..] {
6464
"x86" | "x86_64" => vec!["~{dirflag}", "~{fpsr}", "~{flags}"],
6565
"mips" | "mips64" => vec!["~{$1}"],
6666
_ => Vec::new(),

compiler/rustc_codegen_llvm/src/attributes.rs

+4-6
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ fn inline(cx: &CodegenCx<'ll, '_>, val: &'ll Value, inline: InlineAttr) {
3131
Hint => Attribute::InlineHint.apply_llfn(Function, val),
3232
Always => Attribute::AlwaysInline.apply_llfn(Function, val),
3333
Never => {
34-
if cx.tcx().sess.target.target.arch != "amdgpu" {
34+
if cx.tcx().sess.target.arch != "amdgpu" {
3535
Attribute::NoInline.apply_llfn(Function, val);
3636
}
3737
}
@@ -91,8 +91,7 @@ fn set_instrument_function(cx: &CodegenCx<'ll, '_>, llfn: &'ll Value) {
9191
// The function name varies on platforms.
9292
// See test/CodeGen/mcount.c in clang.
9393
let mcount_name =
94-
CString::new(cx.sess().target.target.options.target_mcount.as_str().as_bytes())
95-
.unwrap();
94+
CString::new(cx.sess().target.options.target_mcount.as_str().as_bytes()).unwrap();
9695

9796
llvm::AddFunctionAttrStringValue(
9897
llfn,
@@ -106,7 +105,7 @@ fn set_instrument_function(cx: &CodegenCx<'ll, '_>, llfn: &'ll Value) {
106105
fn set_probestack(cx: &CodegenCx<'ll, '_>, llfn: &'ll Value) {
107106
// Only use stack probes if the target specification indicates that we
108107
// should be using stack probes
109-
if !cx.sess().target.target.options.stack_probes {
108+
if !cx.sess().target.options.stack_probes {
110109
return;
111110
}
112111

@@ -175,7 +174,6 @@ pub fn llvm_target_features(sess: &Session) -> impl Iterator<Item = &str> {
175174
.split(',')
176175
.filter(|f| !RUSTC_SPECIFIC_FEATURES.iter().any(|s| f.contains(s)));
177176
sess.target
178-
.target
179177
.options
180178
.features
181179
.split(',')
@@ -345,7 +343,7 @@ pub fn from_fn_attrs(cx: &CodegenCx<'ll, 'tcx>, llfn: &'ll Value, instance: ty::
345343
// Note that currently the `wasm-import-module` doesn't do anything, but
346344
// eventually LLVM 7 should read this and ferry the appropriate import
347345
// module to the output file.
348-
if cx.tcx.sess.target.target.arch == "wasm32" {
346+
if cx.tcx.sess.target.arch == "wasm32" {
349347
if let Some(module) = wasm_import_module(cx.tcx, instance.def_id()) {
350348
llvm::AddFunctionAttrStringValue(
351349
llfn,

compiler/rustc_codegen_llvm/src/back/archive.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -206,7 +206,7 @@ impl<'a> LlvmArchiveBuilder<'a> {
206206
}
207207

208208
fn llvm_archive_kind(&self) -> Result<ArchiveKind, &str> {
209-
let kind = &*self.config.sess.target.target.options.archive_format;
209+
let kind = &*self.config.sess.target.options.archive_format;
210210
kind.parse().map_err(|_| kind)
211211
}
212212

compiler/rustc_codegen_llvm/src/back/write.rs

+8-8
Original file line numberDiff line numberDiff line change
@@ -128,40 +128,40 @@ pub fn target_machine_factory(
128128
let (opt_level, _) = to_llvm_opt_settings(optlvl);
129129
let use_softfp = sess.opts.cg.soft_float;
130130

131-
let ffunction_sections = sess.target.target.options.function_sections;
131+
let ffunction_sections = sess.target.options.function_sections;
132132
let fdata_sections = ffunction_sections;
133133

134134
let code_model = to_llvm_code_model(sess.code_model());
135135

136136
let features = attributes::llvm_target_features(sess).collect::<Vec<_>>();
137-
let mut singlethread = sess.target.target.options.singlethread;
137+
let mut singlethread = sess.target.options.singlethread;
138138

139139
// On the wasm target once the `atomics` feature is enabled that means that
140140
// we're no longer single-threaded, or otherwise we don't want LLVM to
141141
// lower atomic operations to single-threaded operations.
142142
if singlethread
143-
&& sess.target.target.llvm_target.contains("wasm32")
143+
&& sess.target.llvm_target.contains("wasm32")
144144
&& sess.target_features.contains(&sym::atomics)
145145
{
146146
singlethread = false;
147147
}
148148

149-
let triple = SmallCStr::new(&sess.target.target.llvm_target);
149+
let triple = SmallCStr::new(&sess.target.llvm_target);
150150
let cpu = SmallCStr::new(llvm_util::target_cpu(sess));
151151
let features = features.join(",");
152152
let features = CString::new(features).unwrap();
153-
let abi = SmallCStr::new(&sess.target.target.options.llvm_abiname);
154-
let trap_unreachable = sess.target.target.options.trap_unreachable;
153+
let abi = SmallCStr::new(&sess.target.options.llvm_abiname);
154+
let trap_unreachable = sess.target.options.trap_unreachable;
155155
let emit_stack_size_section = sess.opts.debugging_opts.emit_stack_sizes;
156156

157157
let asm_comments = sess.asm_comments();
158-
let relax_elf_relocations = sess.target.target.options.relax_elf_relocations;
158+
let relax_elf_relocations = sess.target.options.relax_elf_relocations;
159159

160160
let use_init_array = !sess
161161
.opts
162162
.debugging_opts
163163
.use_ctors_section
164-
.unwrap_or(sess.target.target.options.use_ctors_section);
164+
.unwrap_or(sess.target.options.use_ctors_section);
165165

166166
Arc::new(move || {
167167
let tm = unsafe {

compiler/rustc_codegen_llvm/src/base.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ pub fn write_compressed_metadata<'tcx>(
6060
unsafe { llvm::LLVMAddGlobal(metadata_llmod, common::val_ty(llconst), buf.as_ptr()) };
6161
unsafe {
6262
llvm::LLVMSetInitializer(llglobal, llconst);
63-
let section_name = metadata::metadata_section_name(&tcx.sess.target.target);
63+
let section_name = metadata::metadata_section_name(&tcx.sess.target);
6464
let name = SmallCStr::new(section_name);
6565
llvm::LLVMSetSection(llglobal, name.as_ptr());
6666

compiler/rustc_codegen_llvm/src/builder.rs

+6-6
Original file line numberDiff line numberDiff line change
@@ -308,8 +308,8 @@ impl BuilderMethods<'a, 'tcx> for Builder<'a, 'll, 'tcx> {
308308
use rustc_middle::ty::{Int, Uint};
309309

310310
let new_kind = match ty.kind() {
311-
Int(t @ Isize) => Int(t.normalize(self.tcx.sess.target.ptr_width)),
312-
Uint(t @ Usize) => Uint(t.normalize(self.tcx.sess.target.ptr_width)),
311+
Int(t @ Isize) => Int(t.normalize(self.tcx.sess.target.pointer_width)),
312+
Uint(t @ Usize) => Uint(t.normalize(self.tcx.sess.target.pointer_width)),
313313
t @ (Uint(_) | Int(_)) => t.clone(),
314314
_ => panic!("tried to get overflow intrinsic for op applied to non-int type"),
315315
};
@@ -541,7 +541,7 @@ impl BuilderMethods<'a, 'tcx> for Builder<'a, 'll, 'tcx> {
541541
}
542542

543543
fn range_metadata(&mut self, load: &'ll Value, range: Range<u128>) {
544-
if self.sess().target.target.arch == "amdgpu" {
544+
if self.sess().target.arch == "amdgpu" {
545545
// amdgpu/LLVM does something weird and thinks a i64 value is
546546
// split into a v2i32, halving the bitwidth LLVM expects,
547547
// tripping an assertion. So, for now, just disable this
@@ -671,7 +671,7 @@ impl BuilderMethods<'a, 'tcx> for Builder<'a, 'll, 'tcx> {
671671
// WebAssembly has saturating floating point to integer casts if the
672672
// `nontrapping-fptoint` target feature is activated. We'll use those if
673673
// they are available.
674-
if self.sess().target.target.arch == "wasm32"
674+
if self.sess().target.arch == "wasm32"
675675
&& self.sess().target_features.contains(&sym::nontrapping_dash_fptoint)
676676
{
677677
let src_ty = self.cx.val_ty(val);
@@ -696,7 +696,7 @@ impl BuilderMethods<'a, 'tcx> for Builder<'a, 'll, 'tcx> {
696696
// WebAssembly has saturating floating point to integer casts if the
697697
// `nontrapping-fptoint` target feature is activated. We'll use those if
698698
// they are available.
699-
if self.sess().target.target.arch == "wasm32"
699+
if self.sess().target.arch == "wasm32"
700700
&& self.sess().target_features.contains(&sym::nontrapping_dash_fptoint)
701701
{
702702
let src_ty = self.cx.val_ty(val);
@@ -1427,7 +1427,7 @@ impl Builder<'a, 'll, 'tcx> {
14271427
}
14281428

14291429
fn wasm_and_missing_nontrapping_fptoint(&self) -> bool {
1430-
self.sess().target.target.arch == "wasm32"
1430+
self.sess().target.arch == "wasm32"
14311431
&& !self.sess().target_features.contains(&sym::nontrapping_dash_fptoint)
14321432
}
14331433
}

compiler/rustc_codegen_llvm/src/callee.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -176,7 +176,7 @@ pub fn get_fn(cx: &CodegenCx<'ll, 'tcx>, instance: Instance<'tcx>) -> &'ll Value
176176
// should use dllimport for functions.
177177
if cx.use_dll_storage_attrs
178178
&& tcx.is_dllimport_foreign_item(instance_def_id)
179-
&& tcx.sess.target.target.target_env != "gnu"
179+
&& tcx.sess.target.target_env != "gnu"
180180
{
181181
unsafe {
182182
llvm::LLVMSetDLLStorageClass(llfn, llvm::DLLStorageClass::DllImport);

compiler/rustc_codegen_llvm/src/consts.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ fn set_global_alignment(cx: &CodegenCx<'ll, '_>, gv: &'ll Value, mut align: Alig
9292
// The target may require greater alignment for globals than the type does.
9393
// Note: GCC and Clang also allow `__attribute__((aligned))` on variables,
9494
// which can force it to be smaller. Rust doesn't support this yet.
95-
if let Some(min) = cx.sess().target.target.options.min_global_align {
95+
if let Some(min) = cx.sess().target.options.min_global_align {
9696
match Align::from_bits(min) {
9797
Ok(min) => align = align.max(min),
9898
Err(err) => {
@@ -283,7 +283,7 @@ impl CodegenCx<'ll, 'tcx> {
283283
// argument validation.
284284
debug_assert!(
285285
!(self.tcx.sess.opts.cg.linker_plugin_lto.enabled()
286-
&& self.tcx.sess.target.target.options.is_like_windows
286+
&& self.tcx.sess.target.options.is_like_windows
287287
&& self.tcx.sess.opts.cg.prefer_dynamic)
288288
);
289289

@@ -437,7 +437,7 @@ impl StaticMethods for CodegenCx<'ll, 'tcx> {
437437
// will use load-unaligned instructions instead, and thus avoiding the crash.
438438
//
439439
// We could remove this hack whenever we decide to drop macOS 10.10 support.
440-
if self.tcx.sess.target.target.options.is_like_osx {
440+
if self.tcx.sess.target.options.is_like_osx {
441441
// The `inspect` method is okay here because we checked relocations, and
442442
// because we are doing this access to inspect the final interpreter state
443443
// (not as part of the interpreter execution).

compiler/rustc_codegen_llvm/src/context.rs

+9-9
Original file line numberDiff line numberDiff line change
@@ -118,18 +118,18 @@ pub unsafe fn create_module(
118118
let mod_name = SmallCStr::new(mod_name);
119119
let llmod = llvm::LLVMModuleCreateWithNameInContext(mod_name.as_ptr(), llcx);
120120

121-
let mut target_data_layout = sess.target.target.data_layout.clone();
121+
let mut target_data_layout = sess.target.data_layout.clone();
122122
if llvm_util::get_major_version() < 9 {
123123
target_data_layout = strip_function_ptr_alignment(target_data_layout);
124124
}
125125
if llvm_util::get_major_version() < 10 {
126-
if sess.target.target.arch == "x86" || sess.target.target.arch == "x86_64" {
126+
if sess.target.arch == "x86" || sess.target.arch == "x86_64" {
127127
target_data_layout = strip_x86_address_spaces(target_data_layout);
128128
}
129129
}
130130

131131
// Ensure the data-layout values hardcoded remain the defaults.
132-
if sess.target.target.options.is_builtin {
132+
if sess.target.options.is_builtin {
133133
let tm = crate::back::write::create_informational_target_machine(tcx.sess);
134134
llvm::LLVMRustSetDataLayoutFromTargetMachine(llmod, tm);
135135
llvm::LLVMRustDisposeTargetMachine(tm);
@@ -160,7 +160,7 @@ pub unsafe fn create_module(
160160
bug!(
161161
"data-layout for builtin `{}` target, `{}`, \
162162
differs from LLVM default, `{}`",
163-
sess.target.target.llvm_target,
163+
sess.target.llvm_target,
164164
target_data_layout,
165165
llvm_data_layout
166166
);
@@ -170,7 +170,7 @@ pub unsafe fn create_module(
170170
let data_layout = SmallCStr::new(&target_data_layout);
171171
llvm::LLVMSetDataLayout(llmod, data_layout.as_ptr());
172172

173-
let llvm_target = SmallCStr::new(&sess.target.target.llvm_target);
173+
let llvm_target = SmallCStr::new(&sess.target.llvm_target);
174174
llvm::LLVMRustSetNormalizedTarget(llmod, llvm_target.as_ptr());
175175

176176
if sess.relocation_model() == RelocModel::Pic {
@@ -190,7 +190,7 @@ pub unsafe fn create_module(
190190
}
191191

192192
// Control Flow Guard is currently only supported by the MSVC linker on Windows.
193-
if sess.target.target.options.is_like_msvc {
193+
if sess.target.options.is_like_msvc {
194194
match sess.opts.cg.control_flow_guard {
195195
CFGuard::Disabled => {}
196196
CFGuard::NoChecks => {
@@ -265,7 +265,7 @@ impl<'ll, 'tcx> CodegenCx<'ll, 'tcx> {
265265
// linker will take care of everything. Fixing this problem will likely
266266
// require adding a few attributes to Rust itself (feature gated at the
267267
// start) and then strongly recommending static linkage on Windows!
268-
let use_dll_storage_attrs = tcx.sess.target.target.options.is_like_windows;
268+
let use_dll_storage_attrs = tcx.sess.target.options.is_like_windows;
269269

270270
let check_overflow = tcx.sess.overflow_checks();
271271

@@ -839,7 +839,7 @@ impl CodegenCx<'b, 'tcx> {
839839
return eh_catch_typeinfo;
840840
}
841841
let tcx = self.tcx;
842-
assert!(self.sess().target.target.options.is_like_emscripten);
842+
assert!(self.sess().target.options.is_like_emscripten);
843843
let eh_catch_typeinfo = match tcx.lang_items().eh_catch_typeinfo() {
844844
Some(def_id) => self.get_static(def_id),
845845
_ => {
@@ -878,7 +878,7 @@ impl HasDataLayout for CodegenCx<'ll, 'tcx> {
878878

879879
impl HasTargetSpec for CodegenCx<'ll, 'tcx> {
880880
fn target_spec(&self) -> &Target {
881-
&self.tcx.sess.target.target
881+
&self.tcx.sess.target
882882
}
883883
}
884884

compiler/rustc_codegen_llvm/src/debuginfo/gdb.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -67,5 +67,5 @@ pub fn needs_gdb_debug_scripts_section(cx: &CodegenCx<'_, '_>) -> bool {
6767

6868
!omit_gdb_pretty_printer_section
6969
&& cx.sess().opts.debuginfo != DebugInfo::None
70-
&& cx.sess().target.target.options.emit_debug_gdb_scripts
70+
&& cx.sess().target.options.emit_debug_gdb_scripts
7171
}

compiler/rustc_codegen_llvm/src/debuginfo/metadata.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -874,7 +874,7 @@ fn basic_type_metadata(cx: &CodegenCx<'ll, 'tcx>, t: Ty<'tcx>) -> &'ll DIType {
874874

875875
// When targeting MSVC, emit MSVC style type names for compatibility with
876876
// .natvis visualizers (and perhaps other existing native debuggers?)
877-
let msvc_like_names = cx.tcx.sess.target.target.options.is_like_msvc;
877+
let msvc_like_names = cx.tcx.sess.target.options.is_like_msvc;
878878

879879
let (name, encoding) = match t.kind() {
880880
ty::Never => ("!", DW_ATE_unsigned),
@@ -985,7 +985,7 @@ pub fn compile_unit_metadata(
985985
// if multiple object files with the same `DW_AT_name` are linked together.
986986
// As a workaround we generate unique names for each object file. Those do
987987
// not correspond to an actual source file but that should be harmless.
988-
if tcx.sess.target.target.options.is_like_osx {
988+
if tcx.sess.target.options.is_like_osx {
989989
name_in_debuginfo.push("@");
990990
name_in_debuginfo.push(codegen_unit_name);
991991
}
@@ -1401,7 +1401,7 @@ fn prepare_union_metadata(
14011401
/// on MSVC we have to use the fallback mode, because LLVM doesn't
14021402
/// lower variant parts to PDB.
14031403
fn use_enum_fallback(cx: &CodegenCx<'_, '_>) -> bool {
1404-
cx.sess().target.target.options.is_like_msvc
1404+
cx.sess().target.options.is_like_msvc
14051405
}
14061406

14071407
// FIXME(eddyb) maybe precompute this? Right now it's computed once

compiler/rustc_codegen_llvm/src/debuginfo/mod.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -120,12 +120,12 @@ pub fn finalize(cx: &CodegenCx<'_, '_>) {
120120
// for macOS to understand. For more info see #11352
121121
// This can be overridden using --llvm-opts -dwarf-version,N.
122122
// Android has the same issue (#22398)
123-
if let Some(version) = cx.sess().target.target.options.dwarf_version {
123+
if let Some(version) = cx.sess().target.options.dwarf_version {
124124
llvm::LLVMRustAddModuleFlag(cx.llmod, "Dwarf Version\0".as_ptr().cast(), version)
125125
}
126126

127127
// Indicate that we want CodeView debug information on MSVC
128-
if cx.sess().target.target.options.is_like_msvc {
128+
if cx.sess().target.options.is_like_msvc {
129129
llvm::LLVMRustAddModuleFlag(cx.llmod, "CodeView\0".as_ptr().cast(), 1)
130130
}
131131

@@ -346,7 +346,7 @@ impl DebugInfoMethods<'tcx> for CodegenCx<'ll, 'tcx> {
346346
});
347347

348348
// Arguments types
349-
if cx.sess().target.target.options.is_like_msvc {
349+
if cx.sess().target.options.is_like_msvc {
350350
// FIXME(#42800):
351351
// There is a bug in MSDIA that leads to a crash when it encounters
352352
// a fixed-size array of `u8` or something zero-sized in a

0 commit comments

Comments
 (0)