llvm/mlir/lib/AsmParser/AsmParserState.cpp

//===- AsmParserState.cpp -------------------------------------------------===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
//
//===----------------------------------------------------------------------===//

#include "mlir/AsmParser/AsmParserState.h"
#include "mlir/IR/Attributes.h"
#include "mlir/IR/Operation.h"
#include "mlir/IR/SymbolTable.h"
#include "mlir/IR/Types.h"
#include "mlir/IR/Value.h"
#include "mlir/Support/LLVM.h"
#include "llvm/ADT/ArrayRef.h"
#include "llvm/ADT/STLExtras.h"
#include "llvm/ADT/StringExtras.h"
#include "llvm/ADT/StringMap.h"
#include "llvm/ADT/iterator.h"
#include "llvm/Support/ErrorHandling.h"
#include <cassert>
#include <cctype>
#include <memory>
#include <utility>

usingnamespacemlir;

//===----------------------------------------------------------------------===//
// AsmParserState::Impl
//===----------------------------------------------------------------------===//

struct AsmParserState::Impl {};

void AsmParserState::Impl::resolveSymbolUses() {}

//===----------------------------------------------------------------------===//
// AsmParserState
//===----------------------------------------------------------------------===//

AsmParserState::AsmParserState() :{}
AsmParserState::~AsmParserState() = default;
AsmParserState &AsmParserState::operator=(AsmParserState &&other) {}

//===----------------------------------------------------------------------===//
// Access State

auto AsmParserState::getBlockDefs() const -> iterator_range<BlockDefIterator> {}

auto AsmParserState::getBlockDef(Block *block) const
    -> const BlockDefinition * {}

auto AsmParserState::getOpDefs() const -> iterator_range<OperationDefIterator> {}

auto AsmParserState::getOpDef(Operation *op) const
    -> const OperationDefinition * {}

auto AsmParserState::getAttributeAliasDefs() const
    -> iterator_range<AttributeDefIterator> {}

auto AsmParserState::getAttributeAliasDef(StringRef name) const
    -> const AttributeAliasDefinition * {}

auto AsmParserState::getTypeAliasDefs() const
    -> iterator_range<TypeDefIterator> {}

auto AsmParserState::getTypeAliasDef(StringRef name) const
    -> const TypeAliasDefinition * {}

/// Lex a string token whose contents start at the given `curPtr`. Returns the
/// position at the end of the string, after a terminal or invalid character
/// (e.g. `"` or `\0`).
static const char *lexLocStringTok(const char *curPtr) {}

SMRange AsmParserState::convertIdLocToRange(SMLoc loc) {}

//===----------------------------------------------------------------------===//
// Populate State

void AsmParserState::initialize(Operation *topLevelOp) {}

void AsmParserState::finalize(Operation *topLevelOp) {}

void AsmParserState::startOperationDefinition(const OperationName &opName) {}

void AsmParserState::finalizeOperationDefinition(
    Operation *op, SMRange nameLoc, SMLoc endLoc,
    ArrayRef<std::pair<unsigned, SMLoc>> resultGroups) {}

void AsmParserState::startRegionDefinition() {}

void AsmParserState::finalizeRegionDefinition() {}

void AsmParserState::addDefinition(Block *block, SMLoc location) {}

void AsmParserState::addDefinition(BlockArgument blockArg, SMLoc location) {}

void AsmParserState::addAttrAliasDefinition(StringRef name, SMRange location,
                                            Attribute value) {}

void AsmParserState::addTypeAliasDefinition(StringRef name, SMRange location,
                                            Type value) {}

void AsmParserState::addUses(Value value, ArrayRef<SMLoc> locations) {}

void AsmParserState::addUses(Block *block, ArrayRef<SMLoc> locations) {}

void AsmParserState::addUses(SymbolRefAttr refAttr,
                             ArrayRef<SMRange> locations) {}

void AsmParserState::addAttrAliasUses(StringRef name, SMRange location) {}

void AsmParserState::addTypeAliasUses(StringRef name, SMRange location) {}

void AsmParserState::refineDefinition(Value oldValue, Value newValue) {}