mini-llvm 0.1.0
Loading...
Searching...
No Matches
RISCVDataDirective.h
Go to the documentation of this file.
1// SPDX-License-Identifier: MIT
2
3#pragma once
4
5#include <cstdint>
6#include <cstdlib>
7#include <string>
8
11
12namespace mini_llvm::mc {
13
15public:
17 : width_(width), value_(value) {}
18
19 int width() const {
20 return width_;
21 }
22
23 void setWidth(int width) {
24 width_ = width;
25 }
26
27 int64_t value() const {
28 return value_;
29 }
30
31 void setValue(int64_t value) {
32 value_ = value;
33 }
34
35 std::string format() const override;
36
37private:
38 int width_;
39 int64_t value_;
40};
41
42} // namespace mini_llvm::mc
#define MINI_LLVM_EXPORT
Definition Compiler.h:17
Definition Directive.h:10
std::string format() const override
int64_t value() const
Definition RISCVDataDirective.h:27
void setWidth(int width)
Definition RISCVDataDirective.h:23
RISCVDataDirective(int width, int64_t value)
Definition RISCVDataDirective.h:16
int width() const
Definition RISCVDataDirective.h:19
void setValue(int64_t value)
Definition RISCVDataDirective.h:31
Definition Directive.h:8