14#ifndef MLIR_TABLEGEN_BUILDER_H_
15#define MLIR_TABLEGEN_BUILDER_H_
18#include "llvm/ADT/ArrayRef.h"
19#include "llvm/ADT/SmallVector.h"
20#include "llvm/ADT/StringRef.h"
43 std::optional<StringRef>
getName()
const {
return name; }
50 Parameter(std::optional<StringRef> name,
const llvm::Init *
def)
54 std::optional<StringRef> name;
58 const llvm::Init *
def;
71 std::optional<StringRef>
getBody()
const;
79 const llvm::Record *
def;
This class represents a single parameter to a builder method.
std::optional< StringRef > getDefaultValue() const
Return an optional string containing the default value to use for this parameter.
StringRef getCppType() const
Return a string containing the C++ type of this parameter.
std::optional< StringRef > getName() const
Return an optional string containing the name of this parameter.
Wrapper class with helper methods for accessing Builders defined in TableGen.
Builder(const llvm::Record *record, ArrayRef< SMLoc > loc)
Construct a builder from the given Record instance.
const llvm::Record * def
The TableGen definition of this builder.
std::optional< StringRef > getDeprecatedMessage() const
Return the deprecation message of the builder.
ArrayRef< Parameter > getParameters() const
Return a list of parameters used in this build method.
std::optional< StringRef > getBody() const
Return an optional string containing the body of the builder.
The OpAsmOpInterface, see OpAsmInterface.td for more details.
Include the generated interface declarations.