]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - contrib/llvm/include/llvm/MC/MCAsmMacro.h
dts: Import DTS for arm64
[FreeBSD/FreeBSD.git] / contrib / llvm / include / llvm / MC / MCAsmMacro.h
1 //===- MCAsmMacro.h - Assembly Macros ---------------------------*- C++ -*-===//
2 //
3 //                     The LLVM Compiler Infrastructure
4 //
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
7 //
8 //===----------------------------------------------------------------------===//
9
10 #ifndef LLVM_MC_MCASMMACRO_H
11 #define LLVM_MC_MCASMMACRO_H
12
13 #include "llvm/MC/MCParser/MCAsmLexer.h"
14
15 namespace llvm {
16
17 struct MCAsmMacroParameter {
18   StringRef Name;
19   std::vector<AsmToken> Value;
20   bool Required = false;
21   bool Vararg = false;
22
23   MCAsmMacroParameter() = default;
24 };
25
26 typedef std::vector<MCAsmMacroParameter> MCAsmMacroParameters;
27 struct MCAsmMacro {
28   StringRef Name;
29   StringRef Body;
30   MCAsmMacroParameters Parameters;
31
32 public:
33   MCAsmMacro(StringRef N, StringRef B, MCAsmMacroParameters P)
34       : Name(N), Body(B), Parameters(std::move(P)) {}
35 };
36 } // namespace llvm
37
38 #endif