#include "TestFormatUtils.h"
#include "mlir/IR/Builders.h"
usingnamespacemlir;
usingnamespacetest;
ParseResult test::parseCustomDirectiveOperands(
OpAsmParser &parser, OpAsmParser::UnresolvedOperand &operand,
std::optional<OpAsmParser::UnresolvedOperand> &optOperand,
SmallVectorImpl<OpAsmParser::UnresolvedOperand> &varOperands) { … }
void test::printCustomDirectiveOperands(OpAsmPrinter &printer, Operation *,
Value operand, Value optOperand,
OperandRange varOperands) { … }
ParseResult
test::parseCustomDirectiveResults(OpAsmParser &parser, Type &operandType,
Type &optOperandType,
SmallVectorImpl<Type> &varOperandTypes) { … }
void test::printCustomDirectiveResults(OpAsmPrinter &printer, Operation *,
Type operandType, Type optOperandType,
TypeRange varOperandTypes) { … }
ParseResult test::parseCustomDirectiveWithTypeRefs(
OpAsmParser &parser, Type operandType, Type optOperandType,
const SmallVectorImpl<Type> &varOperandTypes) { … }
void test::printCustomDirectiveWithTypeRefs(OpAsmPrinter &printer,
Operation *op, Type operandType,
Type optOperandType,
TypeRange varOperandTypes) { … }
ParseResult test::parseCustomDirectiveOperandsAndTypes(
OpAsmParser &parser, OpAsmParser::UnresolvedOperand &operand,
std::optional<OpAsmParser::UnresolvedOperand> &optOperand,
SmallVectorImpl<OpAsmParser::UnresolvedOperand> &varOperands,
Type &operandType, Type &optOperandType,
SmallVectorImpl<Type> &varOperandTypes) { … }
void test::printCustomDirectiveOperandsAndTypes(
OpAsmPrinter &printer, Operation *op, Value operand, Value optOperand,
OperandRange varOperands, Type operandType, Type optOperandType,
TypeRange varOperandTypes) { … }
ParseResult test::parseCustomDirectiveRegions(
OpAsmParser &parser, Region ®ion,
SmallVectorImpl<std::unique_ptr<Region>> &varRegions) { … }
void test::printCustomDirectiveRegions(OpAsmPrinter &printer, Operation *,
Region ®ion,
MutableArrayRef<Region> varRegions) { … }
ParseResult
test::parseCustomDirectiveSuccessors(OpAsmParser &parser, Block *&successor,
SmallVectorImpl<Block *> &varSuccessors) { … }
void test::printCustomDirectiveSuccessors(OpAsmPrinter &printer, Operation *,
Block *successor,
SuccessorRange varSuccessors) { … }
ParseResult test::parseCustomDirectiveAttributes(OpAsmParser &parser,
IntegerAttr &attr,
IntegerAttr &optAttr) { … }
void test::printCustomDirectiveAttributes(OpAsmPrinter &printer, Operation *,
Attribute attribute,
Attribute optAttribute) { … }
ParseResult test::parseCustomDirectiveAttrDict(OpAsmParser &parser,
NamedAttrList &attrs) { … }
void test::printCustomDirectiveAttrDict(OpAsmPrinter &printer, Operation *op,
DictionaryAttr attrs) { … }
ParseResult test::parseCustomDirectiveOptionalOperandRef(
OpAsmParser &parser,
std::optional<OpAsmParser::UnresolvedOperand> &optOperand) { … }
void test::printCustomDirectiveOptionalOperandRef(OpAsmPrinter &printer,
Operation *op,
Value optOperand) { … }
ParseResult test::parseCustomOptionalOperand(
OpAsmParser &parser,
std::optional<OpAsmParser::UnresolvedOperand> &optOperand) { … }
void test::printCustomOptionalOperand(OpAsmPrinter &printer, Operation *,
Value optOperand) { … }
ParseResult
test::parseSwitchCases(OpAsmParser &p, DenseI64ArrayAttr &cases,
SmallVectorImpl<std::unique_ptr<Region>> &caseRegions) { … }
void test::printSwitchCases(OpAsmPrinter &p, Operation *op,
DenseI64ArrayAttr cases, RegionRange caseRegions) { … }
bool test::parseUsingPropertyInCustom(OpAsmParser &parser,
SmallVector<int64_t> &value) { … }
void test::printUsingPropertyInCustom(OpAsmPrinter &printer, Operation *op,
ArrayRef<int64_t> value) { … }
bool test::parseIntProperty(OpAsmParser &parser, int64_t &value) { … }
void test::printIntProperty(OpAsmPrinter &printer, Operation *op,
int64_t value) { … }
bool test::parseSumProperty(OpAsmParser &parser, int64_t &second,
int64_t first) { … }
void test::printSumProperty(OpAsmPrinter &printer, Operation *op,
int64_t second, int64_t first) { … }
OptionalParseResult test::parseOptionalCustomParser(AsmParser &p,
IntegerAttr &result) { … }
void test::printOptionalCustomParser(AsmPrinter &p, Operation *,
IntegerAttr result) { … }
ParseResult test::parseAttrElideType(AsmParser &parser, TypeAttr type,
Attribute &attr) { … }
void test::printAttrElideType(AsmPrinter &printer, Operation *op, TypeAttr type,
Attribute attr) { … }