Path: blob/main/contrib/llvm-project/llvm/lib/DebugInfo/PDB/Native/EnumTables.cpp
35293 views
//===- EnumTables.cpp - Enum to string conversion tables --------*- C++ -*-===//1//2// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.3// See https://llvm.org/LICENSE.txt for license information.4// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception5//6//===----------------------------------------------------------------------===//78#include "llvm/DebugInfo/PDB/Native/EnumTables.h"9#include "llvm/DebugInfo/PDB/Native/RawConstants.h"10#include "llvm/Support/ScopedPrinter.h"1112using namespace llvm;13using namespace llvm::pdb;1415#define PDB_ENUM_CLASS_ENT(enum_class, enum) \16{ #enum, std::underlying_type_t<enum_class>(enum_class::enum) }1718#define PDB_ENUM_ENT(ns, enum) \19{ #enum, ns::enum }2021static const EnumEntry<uint16_t> OMFSegMapDescFlagNames[] = {22PDB_ENUM_CLASS_ENT(OMFSegDescFlags, Read),23PDB_ENUM_CLASS_ENT(OMFSegDescFlags, Write),24PDB_ENUM_CLASS_ENT(OMFSegDescFlags, Execute),25PDB_ENUM_CLASS_ENT(OMFSegDescFlags, AddressIs32Bit),26PDB_ENUM_CLASS_ENT(OMFSegDescFlags, IsSelector),27PDB_ENUM_CLASS_ENT(OMFSegDescFlags, IsAbsoluteAddress),28PDB_ENUM_CLASS_ENT(OMFSegDescFlags, IsGroup),29};3031namespace llvm {32namespace pdb {33ArrayRef<EnumEntry<uint16_t>> getOMFSegMapDescFlagNames() {34return ArrayRef(OMFSegMapDescFlagNames);35}36}37}383940