Skip to content

Commit 1d13342

Browse files
committed
[MC] Use FirstTargetSpecifier
1 parent d679516 commit 1d13342

File tree

3 files changed

+6
-10
lines changed

3 files changed

+6
-10
lines changed

llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCExpr.h

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,12 +14,10 @@
1414
namespace llvm {
1515
class HexagonMCExpr : public MCTargetExpr {
1616
public:
17-
enum VariantKind {
17+
enum VariantKind : uint8_t {
1818
VK_None,
1919

20-
// While not strictly necessary, start at a larger number to avoid confusion
21-
// with MCSymbolRefExpr::VariantKind.
22-
VK_DTPREL = 100,
20+
VK_DTPREL = MCSymbolRefExpr::FirstTargetSpecifier,
2321
VK_GD_GOT,
2422
VK_GD_PLT,
2523
VK_GOT,

llvm/lib/Target/PowerPC/MCTargetDesc/PPCMCExpr.h

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -17,12 +17,10 @@ namespace llvm {
1717

1818
class PPCMCExpr : public MCTargetExpr {
1919
public:
20-
enum Specifier {
20+
enum Specifier : uint8_t {
2121
VK_None,
2222

23-
// We currently use both MCSymbolRefExpr::VariantKind and
24-
// PPCMCExpr::Specifier. Start at a larger number to avoid conflicts.
25-
VK_LO = 200,
23+
VK_LO = MCSymbolRefExpr::FirstTargetSpecifier,
2624
VK_HI,
2725
VK_HA,
2826
VK_HIGH,

llvm/lib/Target/RISCV/MCTargetDesc/RISCVMCExpr.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,9 @@ class StringRef;
2222

2323
class RISCVMCExpr : public MCTargetExpr {
2424
public:
25-
enum Specifier {
25+
enum Specifier : uint8_t {
2626
VK_None,
27-
VK_LO,
27+
VK_LO = MCSymbolRefExpr::FirstTargetSpecifier,
2828
VK_HI,
2929
VK_PCREL_LO,
3030
VK_PCREL_HI,

0 commit comments

Comments
 (0)