diff options
author | Fangrui Song <i@maskray.me> | 2025-06-27 22:36:43 -0700 |
---|---|---|
committer | Fangrui Song <i@maskray.me> | 2025-06-27 22:36:43 -0700 |
commit | ac9204de7d4f9010506474b532654fa4bd15edfc (patch) | |
tree | 39cbbd70c43d142340835eca4d815733c2067ed0 /llvm/lib/CodeGen/AsmPrinter/WinException.cpp | |
parent | e121f72c945f30b2f18f02317fe970b7fa2efdeb (diff) | |
download | llvm-ac9204de7d4f9010506474b532654fa4bd15edfc.zip llvm-ac9204de7d4f9010506474b532654fa4bd15edfc.tar.gz llvm-ac9204de7d4f9010506474b532654fa4bd15edfc.tar.bz2 |
MCExpr: Remove VK_None
`enum VariantKind` is deprecated. Targets are encouraged to use their
own relocation specifier constants. MCSymbolRefExpr::create callers with
a VK_None argument should switch to the overload with a VariantKind
parameter.
Diffstat (limited to 'llvm/lib/CodeGen/AsmPrinter/WinException.cpp')
-rw-r--r-- | llvm/lib/CodeGen/AsmPrinter/WinException.cpp | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/llvm/lib/CodeGen/AsmPrinter/WinException.cpp b/llvm/lib/CodeGen/AsmPrinter/WinException.cpp index 55d1350..dccd71f 100644 --- a/llvm/lib/CodeGen/AsmPrinter/WinException.cpp +++ b/llvm/lib/CodeGen/AsmPrinter/WinException.cpp @@ -308,10 +308,8 @@ void WinException::endFuncletImpl() { const MCExpr *WinException::create32bitRef(const MCSymbol *Value) { if (!Value) return MCConstantExpr::create(0, Asm->OutContext); - return MCSymbolRefExpr::create(Value, useImageRel32 - ? MCSymbolRefExpr::VK_COFF_IMGREL32 - : MCSymbolRefExpr::VK_None, - Asm->OutContext); + auto Spec = useImageRel32 ? uint16_t(MCSymbolRefExpr::VK_COFF_IMGREL32) : 0; + return MCSymbolRefExpr::create(Value, Spec, Asm->OutContext); } const MCExpr *WinException::create32bitRef(const GlobalValue *GV) { |