MLIR  20.0.0git
Functions
DialectSymbolParser.cpp File Reference
#include "AsmParserImpl.h"
#include "Parser.h"
#include "mlir/AsmParser/AsmParserState.h"
#include "mlir/IR/AsmState.h"
#include "mlir/IR/Attributes.h"
#include "mlir/IR/BuiltinAttributeInterfaces.h"
#include "mlir/IR/BuiltinAttributes.h"
#include "mlir/IR/BuiltinTypes.h"
#include "mlir/IR/Dialect.h"
#include "mlir/IR/DialectImplementation.h"
#include "mlir/IR/MLIRContext.h"
#include "mlir/Support/LLVM.h"
#include "llvm/Support/MemoryBuffer.h"
#include "llvm/Support/SourceMgr.h"
#include <cassert>
#include <cstddef>
#include <utility>

Go to the source code of this file.

Functions

template<typename Symbol , typename SymbolAliasMap , typename CreateFn >
static Symbol parseExtendedSymbol (Parser &p, AsmParserState *asmState, SymbolAliasMap &aliases, CreateFn &&createSymbol)
 Parse an extended dialect symbol. More...
 
template<typename T , typename ParserFn >
static T parseSymbol (StringRef inputStr, MLIRContext *context, size_t *numReadOut, bool isKnownNullTerminated, ParserFn &&parserFn)
 Parses a symbol, of type 'T', and returns it if parsing was successful. More...
 

Function Documentation

◆ parseExtendedSymbol()

template<typename Symbol , typename SymbolAliasMap , typename CreateFn >
static Symbol parseExtendedSymbol ( Parser p,
AsmParserState asmState,
SymbolAliasMap &  aliases,
CreateFn &&  createSymbol 
)
static

◆ parseSymbol()

template<typename T , typename ParserFn >
static T parseSymbol ( StringRef  inputStr,
MLIRContext context,
size_t *  numReadOut,
bool  isKnownNullTerminated,
ParserFn &&  parserFn 
)
static

Parses a symbol, of type 'T', and returns it if parsing was successful.

If parsing failed, nullptr is returned.

Definition at line 331 of file DialectSymbolParser.cpp.