//===------------------------- MicrosoftDemangle.h --------------*- C++ -*-===// // // 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 // //===----------------------------------------------------------------------===// #ifndef LLVM_DEMANGLE_MICROSOFTDEMANGLE_H #define LLVM_DEMANGLE_MICROSOFTDEMANGLE_H #include "llvm/Demangle/MicrosoftDemangleNodes.h" #include <cassert> #include <string_view> #include <utility> namespace llvm { namespace ms_demangle { // This memory allocator is extremely fast, but it doesn't call dtors // for allocated objects. That means you can't use STL containers // (such as std::vector) with this allocator. But it pays off -- // the demangler is 3x faster with this allocator compared to one with // STL containers. constexpr size_t AllocUnit = …; class ArenaAllocator { … }; struct BackrefContext { … }; enum class QualifierMangleMode { … }; enum NameBackrefBehavior : uint8_t { … }; enum class FunctionIdentifierCodeGroup { … }; // Demangler class takes the main role in demangling symbols. // It has a set of functions to parse mangled symbols into Type instances. // It also has a set of functions to convert Type instances to strings. class Demangler { … }; } // namespace ms_demangle } // namespace llvm #endif // LLVM_DEMANGLE_MICROSOFTDEMANGLE_H