diff options
| author | Dylan DPC <99973273+Dylan-DPC@users.noreply.github.com> | 2022-04-29 23:54:38 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-04-29 23:54:38 +0200 |
| commit | 041f3b64dd0509b87c62ae8b76163127fa488c3e (patch) | |
| tree | eb7564073f3b64e476e624603a8144dc3ab9270e /compiler/rustc_llvm/llvm-wrapper/RustWrapper.cpp | |
| parent | bfb13ec691dc60eec49f58c7ccbe0b34c2680280 (diff) | |
| parent | e8ae06a31bcfa8b276664323fb825af5fce0a885 (diff) | |
| download | rust-041f3b64dd0509b87c62ae8b76163127fa488c3e.tar.gz rust-041f3b64dd0509b87c62ae8b76163127fa488c3e.zip | |
Rollup merge of #96527 - durin42:llvm-15-werror-wswitch, r=nikic
RustWrapper: explicitly don't handle DXILPointerTyID This new enum entry was introduced in https://reviews.llvm.org/D122268, and if I'm reading correctly there's no case where we'd ever encounter it in our uses of LLVM. To preserve the ability to compile this file with -Werror -Wswitch we add an explicit case for this entry. r? nikic
Diffstat (limited to 'compiler/rustc_llvm/llvm-wrapper/RustWrapper.cpp')
| -rw-r--r-- | compiler/rustc_llvm/llvm-wrapper/RustWrapper.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/compiler/rustc_llvm/llvm-wrapper/RustWrapper.cpp b/compiler/rustc_llvm/llvm-wrapper/RustWrapper.cpp index 850b80e4280..6d79e662a42 100644 --- a/compiler/rustc_llvm/llvm-wrapper/RustWrapper.cpp +++ b/compiler/rustc_llvm/llvm-wrapper/RustWrapper.cpp @@ -1217,6 +1217,11 @@ extern "C" LLVMTypeKind LLVMRustGetTypeKind(LLVMTypeRef Ty) { return LLVMBFloatTypeKind; case Type::X86_AMXTyID: return LLVMX86_AMXTypeKind; +#if LLVM_VERSION_GE(15, 0) + case Type::DXILPointerTyID: + report_fatal_error("Rust does not support DirectX typed pointers."); + break; +#endif } report_fatal_error("Unhandled TypeID."); } |
