From ebd941b890e4731aed0ea1f76f056c8a6394f251 Mon Sep 17 00:00:00 2001 From: Tomasz Miąsko Date: Thu, 5 Mar 2020 00:00:00 +0000 Subject: debuginfo: Generators use u32 as discriminant type repr --- src/librustc_codegen_llvm/debuginfo/metadata.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/librustc_codegen_llvm/debuginfo') diff --git a/src/librustc_codegen_llvm/debuginfo/metadata.rs b/src/librustc_codegen_llvm/debuginfo/metadata.rs index 7beaf134e6b..095330a2e4b 100644 --- a/src/librustc_codegen_llvm/debuginfo/metadata.rs +++ b/src/librustc_codegen_llvm/debuginfo/metadata.rs @@ -1802,9 +1802,9 @@ fn prepare_enum_metadata( DIB(cx), name.as_ptr().cast(), name.len(), - // FIXME: what if enumeration has i128 discriminant? - variant_index.as_usize() as i64, - false, // FIXME: IsUnsigned. + // Generators use u32 as discriminant type. + variant_index.as_u32().into(), + true, // IsUnsigned )) } }) -- cgit 1.4.1-3-g733a5