mirror of https://github.com/PCSX2/pcsx2.git
Debugger: Remove the Avast demangler
This library doesn't support the demangling scheme used by GCC 2.x compilers and hence doesn't work in lots of cases.
This commit is contained in:
parent
67d7744f7f
commit
b43e05a8fc
|
@ -1,6 +0,0 @@
|
|||
|
||||
cmake_minimum_required(VERSION 3.6)
|
||||
|
||||
project(demangler CXX)
|
||||
|
||||
add_subdirectory(src)
|
|
@ -1,60 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<Import Project="$(SolutionDir)common\vsprops\BaseProjectConfig.props" />
|
||||
<Import Project="$(SolutionDir)common\vsprops\WinSDK.props" />
|
||||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}</ProjectGuid>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<PlatformToolset Condition="!$(Configuration.Contains(Clang))">$(DefaultPlatformToolset)</PlatformToolset>
|
||||
<PlatformToolset Condition="$(Configuration.Contains(Clang))">ClangCL</PlatformToolset>
|
||||
<CharacterSet>MultiByte</CharacterSet>
|
||||
<WholeProgramOptimization Condition="$(Configuration.Contains(Release))">true</WholeProgramOptimization>
|
||||
<UseDebugLibraries Condition="$(Configuration.Contains(Debug))">true</UseDebugLibraries>
|
||||
<UseDebugLibraries Condition="!$(Configuration.Contains(Debug))">false</UseDebugLibraries>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<ImportGroup Label="ExtensionSettings" />
|
||||
<ImportGroup Label="PropertySheets">
|
||||
<Import Project="..\DefaultProjectRootDir.props" />
|
||||
<Import Project="..\3rdparty.props" />
|
||||
<Import Condition="$(Configuration.Contains(Debug))" Project="..\..\common\vsprops\CodeGen_Debug.props" />
|
||||
<Import Condition="$(Configuration.Contains(Devel))" Project="..\..\common\vsprops\CodeGen_Devel.props" />
|
||||
<Import Condition="$(Configuration.Contains(Release))" Project="..\..\common\vsprops\CodeGen_Release.props" />
|
||||
<Import Condition="!$(Configuration.Contains(Release))" Project="..\..\common\vsprops\IncrementalLinking.props" />
|
||||
</ImportGroup>
|
||||
<PropertyGroup Label="UserMacros" />
|
||||
<PropertyGroup>
|
||||
<CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="src\demangler.cpp" />
|
||||
<ClCompile Include="src\demtools.cpp" />
|
||||
<ClCompile Include="src\gparser.cpp" />
|
||||
<ClCompile Include="src\igrams.cpp" />
|
||||
<ClCompile Include="src\stgrammars\borlandll.cpp" />
|
||||
<ClCompile Include="src\stgrammars\gccll.cpp" />
|
||||
<ClCompile Include="src\stgrammars\msll.cpp" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="include\demangler\demangler.h" />
|
||||
<ClInclude Include="include\demangler\demglobal.h" />
|
||||
<ClInclude Include="include\demangler\demtools.h" />
|
||||
<ClInclude Include="include\demangler\gparser.h" />
|
||||
<ClInclude Include="include\demangler\igrams.h" />
|
||||
<ClInclude Include="include\demangler\stgrammars\borlandll.h" />
|
||||
<ClInclude Include="include\demangler\stgrammars\gccll.h" />
|
||||
<ClInclude Include="include\demangler\stgrammars\msll.h" />
|
||||
</ItemGroup>
|
||||
<ItemDefinitionGroup>
|
||||
<ClCompile>
|
||||
<PreprocessorDefinitions>%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<WarningLevel>TurnOffAllWarnings</WarningLevel>
|
||||
<AdditionalIncludeDirectories>$(ProjectDir)include;$(ProjectDir)src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
<ImportGroup Label="ExtensionTargets" />
|
||||
</Project>
|
|
@ -1,22 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup>
|
||||
<ClCompile Include="src\demangler.cpp" />
|
||||
<ClCompile Include="src\demtools.cpp" />
|
||||
<ClCompile Include="src\gparser.cpp" />
|
||||
<ClCompile Include="src\igrams.cpp" />
|
||||
<ClCompile Include="src\stgrammars\borlandll.cpp" />
|
||||
<ClCompile Include="src\stgrammars\gccll.cpp" />
|
||||
<ClCompile Include="src\stgrammars\msll.cpp" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="include\demangler\demangler.h" />
|
||||
<ClInclude Include="include\demangler\demglobal.h" />
|
||||
<ClInclude Include="include\demangler\demtools.h" />
|
||||
<ClInclude Include="include\demangler\gparser.h" />
|
||||
<ClInclude Include="include\demangler\igrams.h" />
|
||||
<ClInclude Include="include\demangler\stgrammars\borlandll.h" />
|
||||
<ClInclude Include="include\demangler\stgrammars\gccll.h" />
|
||||
<ClInclude Include="include\demangler\stgrammars\msll.h" />
|
||||
</ItemGroup>
|
||||
</Project>
|
|
@ -1,45 +0,0 @@
|
|||
/**
|
||||
* @file include/demangler/demangler.h
|
||||
* @brief Demangler library.
|
||||
* @copyright (c) 2017 Avast Software, licensed under the MIT license
|
||||
*/
|
||||
|
||||
#ifndef DEMANGLER_DEMANGLERL_H
|
||||
#define DEMANGLER_DEMANGLERL_H
|
||||
|
||||
#include <memory>
|
||||
#include <string>
|
||||
|
||||
#include "demangler/gparser.h"
|
||||
|
||||
namespace demangler {
|
||||
|
||||
/**
|
||||
* The grammar parser class - the core of the demangler.
|
||||
*/
|
||||
class CDemangler {
|
||||
cGram *pGram;
|
||||
cName *pName;
|
||||
std::string compiler = "gcc";
|
||||
cGram::errcode errState; /// error state; 0 = everyting is ok
|
||||
|
||||
public:
|
||||
CDemangler(std::string gname, bool i = true);
|
||||
static std::unique_ptr<CDemangler> createGcc(bool i = true);
|
||||
static std::unique_ptr<CDemangler> createMs(bool i = true);
|
||||
static std::unique_ptr<CDemangler> createBorland(bool i = true);
|
||||
virtual ~CDemangler();
|
||||
|
||||
bool isOk();
|
||||
std::string printError();
|
||||
void resetError();
|
||||
|
||||
void createGrammar(std::string inputfilename, std::string outputname);
|
||||
cName *demangleToClass(std::string inputName);
|
||||
std::string demangleToString(std::string inputName);
|
||||
void setSubAnalyze(bool x);
|
||||
};
|
||||
|
||||
} // namespace demangler
|
||||
|
||||
#endif
|
|
@ -1,20 +0,0 @@
|
|||
/**
|
||||
* @file include/demangler/demglobal.h
|
||||
* @brief Global variables in demangler namespace.
|
||||
* @copyright (c) 2017 Avast Software, licensed under the MIT license
|
||||
*/
|
||||
|
||||
#ifndef DEMANGLER_DEMGLOBAL_H
|
||||
#define DEMANGLER_DEMGLOBAL_H
|
||||
|
||||
#include "demangler/igrams.h"
|
||||
|
||||
namespace demangler {
|
||||
|
||||
extern cGram::igram_t internalGrammarStruct;
|
||||
extern cIgram_msll* igram_msll;
|
||||
extern cIgram_gccll* igram_gccll;
|
||||
|
||||
} // namespace demangler
|
||||
|
||||
#endif
|
|
@ -1,36 +0,0 @@
|
|||
/**
|
||||
* @file include/demangler/demtools.h
|
||||
* @brief Tools and extra functions for demangler.
|
||||
* @copyright (c) 2017 Avast Software, licensed under the MIT license
|
||||
*/
|
||||
|
||||
#ifndef DEMANGLER_DEMTOOLS_H
|
||||
#define DEMANGLER_DEMTOOLS_H
|
||||
|
||||
#include <string>
|
||||
|
||||
namespace demangler {
|
||||
|
||||
/**
|
||||
* @brief Structure for date and time.
|
||||
*/
|
||||
struct sdate_t {
|
||||
unsigned int y = 0;
|
||||
unsigned int m = 0;
|
||||
unsigned int d = 0;
|
||||
unsigned int h = 0;
|
||||
unsigned int min = 0;
|
||||
unsigned int s = 0;
|
||||
};
|
||||
|
||||
bool fileExists(const std::string &filename);
|
||||
|
||||
void initSdate_t(sdate_t &x);
|
||||
|
||||
sdate_t genTimeStruct();
|
||||
|
||||
void xreplace(std::string &source, const std::string &tobereplaced, const std::string &replacement);
|
||||
|
||||
} // namespace demangler
|
||||
|
||||
#endif
|
|
@ -1,830 +0,0 @@
|
|||
/**
|
||||
* @file include/demangler/gparser.h
|
||||
* @brief Parser of LL grammar.
|
||||
* @copyright (c) 2017 Avast Software, licensed under the MIT license
|
||||
*/
|
||||
|
||||
#ifndef DEMANGLER_GPARSER_H
|
||||
#define DEMANGLER_GPARSER_H
|
||||
|
||||
#include <map>
|
||||
#include <set>
|
||||
#include <stack>
|
||||
#include <string>
|
||||
#include <utility>
|
||||
#include <vector>
|
||||
|
||||
//internal grammars
|
||||
|
||||
namespace demangler {
|
||||
|
||||
/**
|
||||
* @brief Class which holds a demangled name.
|
||||
*/
|
||||
class cName {
|
||||
public:
|
||||
/**
|
||||
* @brief Enum of types of the mangled types (Determines whether a type is built-in or named).
|
||||
*/
|
||||
enum ttype { //type of type
|
||||
TT_UNKNOWN = 0, //can be used for unknown return type
|
||||
TT_BUILTIN,
|
||||
TT_NAME,
|
||||
TT_NUM,
|
||||
TT_PEXPR
|
||||
};
|
||||
|
||||
/**
|
||||
* @brief Enum of types of the mangled names.
|
||||
*/
|
||||
enum ntype { //type of the mangled name
|
||||
NT_FUNCTION = 0,
|
||||
NT_TEMPLFUNCTION,
|
||||
NT_OPERATOR,
|
||||
NT_CONSTRUCTOR,
|
||||
NT_DESTRUCTOR,
|
||||
NT_DATA,
|
||||
NT_VTABLE,
|
||||
NT_R0,
|
||||
NT_R1,
|
||||
NT_R2,
|
||||
NT_R3,
|
||||
NT_R4,
|
||||
NT__A,
|
||||
NT__B,
|
||||
NT__C,
|
||||
NT__D,
|
||||
NT__E,
|
||||
NT__F,
|
||||
NT__G,
|
||||
NT__H,
|
||||
NT__I,
|
||||
NT__J,
|
||||
NT__K,
|
||||
NT__L,
|
||||
NT__M,
|
||||
NT__N,
|
||||
NT__O,
|
||||
NT__P,
|
||||
NT__Q,
|
||||
NT__R,
|
||||
NT__S,
|
||||
NT__T,
|
||||
NT__U,
|
||||
NT__V,
|
||||
NT__W,
|
||||
NT__X,
|
||||
NT__Y,
|
||||
NT__Z,
|
||||
NT_CLASS
|
||||
};
|
||||
|
||||
/**
|
||||
* @brief Enum of operator types.
|
||||
*/
|
||||
enum optype { //type of operator
|
||||
OT_NULL = 0,
|
||||
OT_NEW,
|
||||
OT_NEWARR,
|
||||
OT_DEL,
|
||||
OT_DELARR,
|
||||
OT_UPLUS,
|
||||
OT_UMINUS,
|
||||
OT_UAND,
|
||||
OT_UAST,
|
||||
OT_TILDA,
|
||||
OT_PLUS,
|
||||
OT_MINUS,
|
||||
OT_AST,
|
||||
OT_DIV,
|
||||
OT_MOD,
|
||||
OT_AND,
|
||||
OT_OR,
|
||||
OT_EXP,
|
||||
OT_ASSIGN,
|
||||
OT_PLUSASS,
|
||||
OT_MINUSASS,
|
||||
OT_ASTASS,
|
||||
OT_DIVASS,
|
||||
OT_MODASS,
|
||||
OT_ANDASS,
|
||||
OT_ORASS,
|
||||
OT_EXPASS,
|
||||
OT_LSHIFT,
|
||||
OT_RSHIFT,
|
||||
OT_LSHIFTASS,
|
||||
OT_RSHIFTASS,
|
||||
OT_EQ,
|
||||
OT_NEQ,
|
||||
OT_LT,
|
||||
OT_GT,
|
||||
OT_LE,
|
||||
OT_GE,
|
||||
OT_NOT,
|
||||
OT_ANDAND,
|
||||
OT_OROR,
|
||||
OT_PLUSPLUS,
|
||||
OT_MINUSMINUS,
|
||||
OT_COMMA,
|
||||
OT_PTAST,
|
||||
OT_PT,
|
||||
OT_BRACKETS,
|
||||
OT_ARR,
|
||||
OT_QUESTION,
|
||||
OT_SIZEOFT,
|
||||
OT_SIZEOFE,
|
||||
OT_ALIGNOFT,
|
||||
OT_ALIGNOFE,
|
||||
OT_CAST
|
||||
};
|
||||
|
||||
/**
|
||||
* @brief Enum of built-in types.
|
||||
*/
|
||||
enum st_type { //standard built-in types
|
||||
T_VOID = 0,
|
||||
T_WCHAR,
|
||||
T_BOOL,
|
||||
T_CHAR,
|
||||
T_SCHAR,
|
||||
T_UCHAR,
|
||||
T_SHORT,
|
||||
T_USHORT,
|
||||
T_INT,
|
||||
T_UINT,
|
||||
T_LONG,
|
||||
T_ULONG,
|
||||
T_LONGLONG,
|
||||
T_ULONGLONG,
|
||||
T_INT128,
|
||||
T_UINT128,
|
||||
T_FLOAT,
|
||||
T_DOUBLE,
|
||||
T_LONGDOUBLE,
|
||||
T_FLOAT128,
|
||||
T_ELLIPSIS,
|
||||
T_DD,
|
||||
T_DE,
|
||||
T_DF,
|
||||
T_DH,
|
||||
T_CHAR32,
|
||||
T_CHAR16,
|
||||
T_AUTO,
|
||||
T_NULLPTR
|
||||
};
|
||||
|
||||
/**
|
||||
* @brief Enum of member function accessibility.
|
||||
*/
|
||||
enum memfacc_t { //standard built-in types
|
||||
MFM_NULL = 0,
|
||||
MFM_PRIVATE,
|
||||
MFM_PUBLIC,
|
||||
MFM_PROTECTED
|
||||
};
|
||||
|
||||
/**
|
||||
* @brief Enum of function call conventions.
|
||||
*/
|
||||
enum fcall_t { //standard built-in types
|
||||
FCC_NULL = 0,
|
||||
FCC_CDECL,
|
||||
FCC_PASCAL,
|
||||
FCC_FORTRAN,
|
||||
FCC_THISCALL,
|
||||
FCC_STDCALL,
|
||||
FCC_FASTCALL,
|
||||
FCC_INTERRUPT
|
||||
};
|
||||
|
||||
/**
|
||||
* @brief Enum of named type classifications. Union, Struct, Class, Enum.
|
||||
*/
|
||||
enum mstype_t { //standard built-in types
|
||||
MST_NULL = 0,
|
||||
MST_UNION,
|
||||
MST_STRUCT,
|
||||
MST_CLASS,
|
||||
MST_ENUM
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* @brief Structure of an unqualified name.
|
||||
* @param un String which holds the name.
|
||||
* @param tpl Pointer to the the template (vector of types) of this unqualified name. If nullptr, the unqualified name consists only of the string.
|
||||
*/
|
||||
struct name_t {
|
||||
std::string un; //unqualified name
|
||||
void *tpl = nullptr; //std::vector<type_t>
|
||||
bool op = false; //is it operator name element?
|
||||
};
|
||||
|
||||
/**
|
||||
* @brief Structure of a type.
|
||||
* @param type Type of the type.
|
||||
* @param b Built-in type. This value is defined only if 'type' is TT_BUILTIN.
|
||||
* @param n Qualified name of the type. This value is defined only if 'type' is TT_NAME.
|
||||
* @param is_const Bool value which determines whether the type is const.
|
||||
* @param is_restrict Bool value which determines whether the type is restrict.
|
||||
* @param is_volatile Bool value which determines whether the type is volatile.
|
||||
* @param is_pointer Integer value determining the pointer level of the type.
|
||||
* @param is_reference Bool value which determines whether the type is a reference.
|
||||
* @param is_rvalue Bool value which determines whether the type is an R-value.
|
||||
* @param is_cpair Bool value which determines whether the type is a complex pair.
|
||||
* @param is_imaginary Bool value which determines whether the type is imaginary.
|
||||
*/
|
||||
struct type_t {
|
||||
ttype type = TT_UNKNOWN; //type of type... builtin or named type
|
||||
st_type b = T_VOID; //builtin type
|
||||
void *value = nullptr; //expression value
|
||||
std::vector<name_t> n; //qualified name of named type
|
||||
std::string modifiers;
|
||||
mstype_t mst = MST_NULL;
|
||||
int num = 0;
|
||||
|
||||
bool is_array = false;
|
||||
std::vector<unsigned int> array_dimensions;
|
||||
bool is_const = false;
|
||||
bool is_restrict = false;
|
||||
bool is_volatile = false;
|
||||
unsigned int is_pointer = 0;
|
||||
bool is_reference = false;
|
||||
bool is_rvalue = false; //r-value reference
|
||||
bool is_cpair = false; //complex pair
|
||||
bool is_imaginary = false;
|
||||
|
||||
std::string getLlvmType();
|
||||
|
||||
private:
|
||||
std::string llvmIr;
|
||||
std::string getLlvmTypePrivate();
|
||||
};
|
||||
|
||||
ntype name_type = NT_FUNCTION; //name type
|
||||
optype operator_type = OT_NULL; //type of operator. it is OT_NULL if function is not an operator
|
||||
type_t return_type;
|
||||
type_t special_type; //return value for function or conversion type for operator OT_CAST
|
||||
std::string modifiers;
|
||||
|
||||
memfacc_t member_function_access = MFM_NULL;
|
||||
fcall_t function_call = FCC_NULL;
|
||||
bool is_static = false;
|
||||
bool is_virtual = false;
|
||||
std::string storage_class;
|
||||
std::vector<long int> rttibcd;
|
||||
|
||||
std::vector<type_t> parameters; //function parameters
|
||||
std::vector<name_t> name; //qualified name composed of unqualified names
|
||||
|
||||
void *tf_tpl = nullptr;
|
||||
|
||||
bool last_shown_endtpl = false; //an auxiliary variable which helps to add space between multiple '>' at the end of templates
|
||||
|
||||
void deleteparams(std::vector<type_t> & vec);
|
||||
cName(); //constructor
|
||||
virtual ~cName(); //mass destruction
|
||||
void type_t_clear(type_t &x);
|
||||
void addname(const std::vector<name_t> & inname); //set the function name
|
||||
void addpar(const std::vector<type_t> & inpar); //set the parameters of the name
|
||||
void setnametype(ntype x); //set type of the mangled name
|
||||
void setfcall(fcall_t x); //set type of the function call convention
|
||||
void setmfacc(memfacc_t x); //set type of the member function access level
|
||||
ntype getnametype(void); //get type of the mangled name
|
||||
void setop(optype x); //set operator type
|
||||
void setret(type_t x); //set return type
|
||||
void setspec(type_t x); //set special type
|
||||
void setstatic(); //set name's static flag
|
||||
void setvirtual(); //set name's virtual flag
|
||||
void addmodifier(char x); //add a modifier to the name modifier string
|
||||
void addstcl(char x); //add a modifier to the storage class string
|
||||
void setmodifiers(std::string x); //set modifiers
|
||||
void settftpl(void* x); //set template function template
|
||||
void addrttinum(long int x); //add a RTTI Base Class descriptor num
|
||||
std::string optypetostr(optype x); //operator type to string
|
||||
std::string printmodifiers(std::string x, bool space);
|
||||
std::string printpremodifiers(std::string x, bool space);
|
||||
std::string printpostmodifiers(std::string x, bool space);
|
||||
std::string printname(std::vector<name_t> & vec, std::string compiler = "gcc");
|
||||
std::string printparams(std::vector<type_t> & vec, bool ignorevoid = false, std::string compiler = "gcc");
|
||||
std::string printpexpr(type_t & x);
|
||||
|
||||
/**
|
||||
* @brief Print the calling convention to a string.
|
||||
* @param callconv The calling convention to be printed.
|
||||
* @return String containing calling convention.
|
||||
*/
|
||||
std::string printcallingconvention(fcall_t callconv);
|
||||
|
||||
std::string printall(std::string compiler = "gcc");
|
||||
std::string printall_old(bool msvcpp = false);
|
||||
}; //class cName
|
||||
|
||||
/**
|
||||
* @brief Grammar class. It's member functions allow loading an external grammar and demangling a mangled name using the grammar.
|
||||
*/
|
||||
class cGram {
|
||||
|
||||
public:
|
||||
/**
|
||||
* @brief Global array of semantic action names. Used when building internal LL table from external grammar.
|
||||
*/
|
||||
static const char *semactname[];
|
||||
|
||||
/**
|
||||
* @brief Enum of error codes.
|
||||
*/
|
||||
enum errcode {
|
||||
ERROR_OK = 0,
|
||||
ERROR_FILE,
|
||||
ERROR_FSM,
|
||||
ERROR_SYN,
|
||||
ERROR_MEM,
|
||||
ERROR_GRAM,
|
||||
ERROR_LL,
|
||||
ERROR_UNK
|
||||
};
|
||||
|
||||
/**
|
||||
* @brief An array of error messages.
|
||||
*/
|
||||
static const char *errmsg[];
|
||||
|
||||
/**
|
||||
* @brief Type of a grammar element. It can be either a terminal or a non-terminal.
|
||||
*/
|
||||
enum gelemtype {
|
||||
GE_TERM = 0,
|
||||
GE_NONTERM
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* @brief Structure of a grammar element.
|
||||
* @param type Type of the element (terminal or non-terminal).
|
||||
* @param nt The name of the non-terminal. Only vylid if type is GE_NONTERM.
|
||||
* @param t The byte value of the terminal. Only valid if type is GE_TERM.
|
||||
*/
|
||||
struct gelem_t {
|
||||
gelem_t(gelemtype t, char* n, unsigned int i, char c) :
|
||||
type(t),
|
||||
nt(n),
|
||||
ntst(i),
|
||||
t(c)
|
||||
{}
|
||||
gelem_t() {}
|
||||
gelemtype type = GE_TERM;
|
||||
char* nt = nullptr;
|
||||
unsigned int ntst = 0;
|
||||
char t = 0;
|
||||
};
|
||||
|
||||
/**
|
||||
* @brief Enum of semantic actions.
|
||||
*/
|
||||
enum semact {
|
||||
//do nothing
|
||||
SA_NULL = 0,
|
||||
|
||||
//set type of name (function, operator, constructor, destructor, data)
|
||||
SA_SETNAMEF,
|
||||
SA_SETNAMETF,
|
||||
SA_SETNAMEO,
|
||||
SA_SETNAMEC,
|
||||
SA_SETNAMED,
|
||||
SA_SETNAMEX,
|
||||
SA_SETNAMEVT,
|
||||
|
||||
//set operator type
|
||||
SA_SETOPXX,
|
||||
SA_SETOPNW,
|
||||
SA_SETOPNA,
|
||||
SA_SETOPDL,
|
||||
SA_SETOPDA,
|
||||
SA_SETOPPS,
|
||||
SA_SETOPNG,
|
||||
SA_SETOPAD,
|
||||
SA_SETOPDE,
|
||||
SA_SETOPCO,
|
||||
SA_SETOPPL,
|
||||
SA_SETOPMI,
|
||||
SA_SETOPML,
|
||||
SA_SETOPDV,
|
||||
SA_SETOPRM,
|
||||
SA_SETOPAN,
|
||||
SA_SETOPOR,
|
||||
SA_SETOPEO,
|
||||
SA_SETOPASS,
|
||||
SA_SETOPPLL,
|
||||
SA_SETOPMII,
|
||||
SA_SETOPMLL,
|
||||
SA_SETOPDVV,
|
||||
SA_SETOPRMM,
|
||||
SA_SETOPANN,
|
||||
SA_SETOPORR,
|
||||
SA_SETOPEOO,
|
||||
SA_SETOPLS,
|
||||
SA_SETOPRS,
|
||||
SA_SETOPLSS,
|
||||
SA_SETOPRSS,
|
||||
SA_SETOPEQ,
|
||||
SA_SETOPNE,
|
||||
SA_SETOPLT,
|
||||
SA_SETOPGT,
|
||||
SA_SETOPLE,
|
||||
SA_SETOPGE,
|
||||
SA_SETOPNT,
|
||||
SA_SETOPAA,
|
||||
SA_SETOPOO,
|
||||
SA_SETOPPP,
|
||||
SA_SETOPMM,
|
||||
SA_SETOPCM,
|
||||
SA_SETOPPM,
|
||||
SA_SETOPPT,
|
||||
SA_SETOPCL,
|
||||
SA_SETOPIX,
|
||||
SA_SETOPQU,
|
||||
SA_SETOPST,
|
||||
SA_SETOPSZ,
|
||||
SA_SETOPAT,
|
||||
SA_SETOPAZ,
|
||||
SA_SETOPCV,
|
||||
|
||||
//builtin types
|
||||
SA_SETTYPEV,
|
||||
SA_SETTYPEW,
|
||||
SA_SETTYPEB,
|
||||
SA_SETTYPEC,
|
||||
SA_SETTYPEA,
|
||||
SA_SETTYPEH,
|
||||
SA_SETTYPES,
|
||||
SA_SETTYPET,
|
||||
SA_SETTYPEI,
|
||||
SA_SETTYPEJ,
|
||||
SA_SETTYPEL,
|
||||
SA_SETTYPEM,
|
||||
SA_SETTYPEX,
|
||||
SA_SETTYPEY,
|
||||
SA_SETTYPEN,
|
||||
SA_SETTYPEO,
|
||||
SA_SETTYPEF,
|
||||
SA_SETTYPED,
|
||||
SA_SETTYPEE,
|
||||
SA_SETTYPEG,
|
||||
SA_SETTYPEZ,
|
||||
|
||||
//parameter modifiers
|
||||
SA_SETCONST,
|
||||
SA_SETRESTRICT,
|
||||
SA_SETVOLATILE,
|
||||
SA_SETPTR,
|
||||
SA_SETREF,
|
||||
SA_SETRVAL,
|
||||
SA_SETCPAIR,
|
||||
SA_SETIM,
|
||||
|
||||
//substitutions
|
||||
SA_SUBSTD, //::std::
|
||||
SA_SUBALC, //::std::allocator
|
||||
SA_SUBSTR, //::std::basic_string
|
||||
SA_SUBSTRS, //::std::basic_string<char,::std::char_traits<char>,::std::allocator<char>>
|
||||
SA_SUBISTR, //::std::basic_istream<char, std::char_traits<char>>
|
||||
SA_SUBOSTR, //::std::basic_ostream<char, std::char_traits<char>>
|
||||
SA_SUBIOSTR, //::std::basic_iostream<char, std::char_traits<char>>
|
||||
|
||||
//other very important semantic actions
|
||||
SA_LOADID, //load an unqualified name into the qualified vector of names
|
||||
SA_LOADSUB, //load a substitution
|
||||
SA_LOADTSUB, //load a template sub
|
||||
SA_LOADARR, //load an array dimension
|
||||
SA_STOREPAR, //store current parameter to vector of parameters
|
||||
SA_STORETEMPARG, //store current parameter to current vector of template arguments
|
||||
SA_STORETEMPLATE, //store the whole template into the last name element of last name vector
|
||||
SA_BEGINTEMPL, //begin a template
|
||||
SA_SKIPTEMPL, //skip a template
|
||||
SA_PAR2F, //store current vector of parameters into the function
|
||||
SA_PAR2RET, //store current parameter to the return value
|
||||
SA_PAR2SPEC, //store current parameter to the special value
|
||||
SA_UNQ2F, //future identifiers are added to the function name
|
||||
SA_UNQ2P, //function identifiers are added to parameter name
|
||||
|
||||
//substitution expansion modifiers
|
||||
SA_SSNEST, //nested sub
|
||||
SA_STUNQ, //unqualified std:: sub
|
||||
SA_SSNO, //other sub derived from <name>
|
||||
|
||||
SA_TYPE2EXPR, //builtin type is converted to primary expression
|
||||
SA_EXPRVAL, //load expression value
|
||||
SA_BEGINPEXPR, //begin a primary expression
|
||||
SA_STOREPEXPR, //end a primary expression
|
||||
SA_COPYTERM, //copy the terminal on the input into current_name in substitution analyzer
|
||||
|
||||
SA_ADDCHARTONAME, //add current character to current unqualified name
|
||||
SA_STORENAME, //move current unqualified name into current name vector
|
||||
SA_REVERSENAME,
|
||||
SA_SETPRIVATE,
|
||||
SA_SETPUBLIC,
|
||||
SA_SETPROTECTED,
|
||||
SA_SETFCDECL,
|
||||
SA_SETFPASCAL,
|
||||
SA_SETFFORTRAN,
|
||||
SA_SETFTHISCALL,
|
||||
SA_SETFSTDCALL,
|
||||
SA_SETFFASTCALL,
|
||||
SA_SETFINTERRUPT,
|
||||
SA_SETUNION,
|
||||
SA_SETSTRUCT,
|
||||
SA_SETCLASS,
|
||||
SA_SETENUM,
|
||||
SA_SETSTATIC,
|
||||
SA_SETVIRTUAL,
|
||||
SA_STCLCONST,
|
||||
SA_STCLVOL,
|
||||
SA_STCLFAR,
|
||||
SA_STCLHUGE,
|
||||
SA_SAVENAMESUB,
|
||||
SA_LOADNAMESUB,
|
||||
SA_MSTEMPLPSUB,
|
||||
SA_SETNAMER0,
|
||||
SA_SETNAMER1,
|
||||
SA_SETNAMER2,
|
||||
SA_SETNAMER3,
|
||||
SA_SETNAMER4,
|
||||
SA_SETNAME_A,
|
||||
SA_SETNAME_B,
|
||||
SA_SETNAME_C,
|
||||
SA_SETNAME_D,
|
||||
SA_SETNAME_E,
|
||||
SA_SETNAME_F,
|
||||
SA_SETNAME_G,
|
||||
SA_SETNAME_H,
|
||||
SA_SETNAME_I,
|
||||
SA_SETNAME_J,
|
||||
SA_SETNAME_K,
|
||||
SA_SETNAME_L,
|
||||
SA_SETNAME_M,
|
||||
SA_SETNAME_N,
|
||||
SA_SETNAME_O,
|
||||
SA_SETNAME_P,
|
||||
SA_SETNAME_Q,
|
||||
SA_SETNAME_R,
|
||||
SA_SETNAME_S,
|
||||
SA_SETNAME_T,
|
||||
SA_SETNAME_U,
|
||||
SA_SETNAME_V,
|
||||
SA_SETNAME_W,
|
||||
SA_SETNAME_X,
|
||||
SA_SETNAME_Y,
|
||||
SA_SETNAME_Z,
|
||||
SA_TEMPL2TFTPL,
|
||||
SA_BEGINBSUB,
|
||||
SA_LOADBSUB,
|
||||
SA_ADDMCONST,
|
||||
SA_ADDMVOL,
|
||||
SA_ADDMFAR,
|
||||
SA_ADDMHUGE,
|
||||
SA_LOADMSNUM,
|
||||
SA_NUMTORTTIBCD,
|
||||
SA_NUMTOTYPE,
|
||||
SA_BORLANDNORMALIZEPARNAME,
|
||||
SA_BORLANDID,
|
||||
SA_LOADBORLANDSUB,
|
||||
SA_BORLANDARR,
|
||||
SA_END
|
||||
};
|
||||
|
||||
/**
|
||||
* @brief Structure of an element in an internal LL table.
|
||||
* @param n Rule number. Numbered from 1. 0 is reserved for "no rule", which indicates a syntax error.
|
||||
* @param s Semantic action to be done when this LL element is used.
|
||||
*/
|
||||
struct llelem_t {
|
||||
llelem_t(unsigned int i, semact ss) :
|
||||
n(i),
|
||||
s(ss)
|
||||
{}
|
||||
llelem_t() {}
|
||||
unsigned int n = 0;
|
||||
semact s = SA_NULL;
|
||||
};
|
||||
|
||||
/**
|
||||
* @brief Struct used to describe a rule boundaries in an internal LL table.
|
||||
* @param offset Offset from the start of ruleelements array.
|
||||
* @param size Number of elements in the current rule.
|
||||
*/
|
||||
struct ruleaddr_t {
|
||||
ruleaddr_t(unsigned int o, unsigned int s) :
|
||||
offset(o),
|
||||
size(s)
|
||||
{}
|
||||
unsigned int offset = 0;
|
||||
unsigned int size = 0;
|
||||
};
|
||||
|
||||
/**
|
||||
* @brief Structure of a grammar rule.
|
||||
* @param n Number of the rule. Numbered from 1. 0 is reserved for "no rule", which indicates a syntax error.
|
||||
* @param left The left side of the rule, consisting of only one non-terminal.
|
||||
* @param right The right side of the rule, which is a sequence of terminals or non-terminals. May be empty.
|
||||
*/
|
||||
struct rule_t {
|
||||
unsigned int n = 0;
|
||||
gelem_t left;
|
||||
std::vector<gelem_t> right;
|
||||
};
|
||||
|
||||
/**
|
||||
* @brief Types of substitution expansion.
|
||||
*/
|
||||
enum subtype {
|
||||
ST_NULL = 0,
|
||||
ST_STUNQ,
|
||||
ST_SSNEST,
|
||||
ST_SSNO
|
||||
};
|
||||
|
||||
/**
|
||||
* @brief States of the FSM for parsing grammar rules from a file.
|
||||
*/
|
||||
enum fsmstate {
|
||||
S_START = 0, //beginning of a line
|
||||
S_NT_LEFT, //non-terminal on the left side
|
||||
S_OP1, //:
|
||||
S_OP2, //:
|
||||
S_OP3, //=
|
||||
S_RIGHT, //right side
|
||||
S_NT_RIGHT, //non-terminal on the right side
|
||||
S_T, //terminal on the right side
|
||||
S_QT, //quoted terminal on the right side
|
||||
S_QT_ESC, //escape sequence of a quoted terminal
|
||||
S_IGNORE, //ignore the rest of the line
|
||||
S_ERROR, //error ocurred
|
||||
S_NULL //just a NULL terminator for the array of final states
|
||||
};
|
||||
|
||||
/**
|
||||
* @brief Class for comparing two grammar element structures. Used in std::set of grammar elements.
|
||||
*/
|
||||
class comparegelem_c {
|
||||
public:
|
||||
/**
|
||||
* @brief Comparison function for two grammar element structures
|
||||
* @param t1 First grammar element.
|
||||
* @param t2 Second grammar element.
|
||||
*/
|
||||
bool operator() (const gelem_t t1, const gelem_t t2) const {
|
||||
//if types don't match, terminal is less than non-terminal
|
||||
if (t1.type!= t2.type) {
|
||||
return (t1.type == GE_TERM)?true:false;
|
||||
}
|
||||
//for two terminals, compare their byte values
|
||||
if (t1.type == GE_TERM) {
|
||||
return t1.t < t2.t;
|
||||
}
|
||||
//for two non-terminals, compare the non-terminal name strings
|
||||
else {
|
||||
return t1.nt < t2.nt;
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
/**
|
||||
* @brief Struct for internal grammar.
|
||||
*/
|
||||
struct igram_t {
|
||||
igram_t(unsigned int tsx, unsigned int rax, unsigned int rex, unsigned int lx, unsigned int ly,
|
||||
gelem_t r, unsigned char* ts, ruleaddr_t* ra, gelem_t* re, llelem_t** lt) :
|
||||
terminal_static_x(tsx),
|
||||
ruleaddrs_x(rax),
|
||||
ruleelements_x(rex),
|
||||
llst_x(lx),
|
||||
llst_y(ly),
|
||||
root(r),
|
||||
terminal_static(ts),
|
||||
ruleaddrs(ra),
|
||||
ruleelements(re),
|
||||
llst(lt)
|
||||
{}
|
||||
igram_t() {}
|
||||
//dimensions of the arrays
|
||||
unsigned int terminal_static_x = 0;
|
||||
unsigned int ruleaddrs_x = 0;
|
||||
unsigned int ruleelements_x = 0;
|
||||
unsigned int llst_x = 0; //first one
|
||||
unsigned int llst_y = 0; //second one
|
||||
//root element
|
||||
gelem_t root;
|
||||
//the arrays
|
||||
unsigned char* terminal_static = nullptr; //array of used terminals
|
||||
ruleaddr_t* ruleaddrs = nullptr; //structures defining offset and size of each rule in the ruleelements table
|
||||
gelem_t* ruleelements = nullptr; //all elements of all rules
|
||||
llelem_t** llst = nullptr; //the LL table
|
||||
};
|
||||
|
||||
/**
|
||||
* @brief The struct variable containing pointers to internal grammar data.
|
||||
*/
|
||||
cGram::igram_t internalGrammarStruct;
|
||||
|
||||
//FSM for parsing external rules
|
||||
static const fsmstate fsm_final[];
|
||||
static const gelem_t T_EOF;
|
||||
|
||||
|
||||
bool internalGrammar = false;
|
||||
std::string compiler;
|
||||
|
||||
/*
|
||||
* Variables used for generation of new internal grammars
|
||||
*/
|
||||
std::string createIGrammar; //if this thing is on, new internal grammar will be generated from external grammar file
|
||||
unsigned int newIG_terminal_static_x = 0;
|
||||
std::size_t newIG_ruleaddrs_x = 0;
|
||||
std::size_t newIG_ruleelements_x = 0;
|
||||
std::size_t newIG_llst_x = 0;
|
||||
std::size_t newIG_llst_y = 0;
|
||||
std::string newIG_root;
|
||||
std::string newIG_terminal_static;
|
||||
std::string newIG_ruleaddrs;
|
||||
std::string newIG_ruleelements;
|
||||
std::string newIG_llst;
|
||||
|
||||
|
||||
/*
|
||||
* Variables for parsed external grammar
|
||||
*/
|
||||
std::vector<rule_t> rules;
|
||||
std::map<std::string,bool> empty;
|
||||
std::map<std::string,std::set<gelem_t,comparegelem_c>> first;
|
||||
std::map<std::string,std::set<gelem_t,comparegelem_c>> follow;
|
||||
std::map<unsigned int,std::set<gelem_t,comparegelem_c>> predict;
|
||||
std::map<std::string,std::map<char,std::pair<unsigned int, semact>>> ll;
|
||||
|
||||
std::vector<unsigned char> terminals;
|
||||
std::vector<std::string> nonterminals;
|
||||
|
||||
size_t lex_position = 0; //position in the source file
|
||||
std::fstream *source = nullptr; //pointer to the input filestream
|
||||
|
||||
/*
|
||||
* methods
|
||||
*/
|
||||
errcode loadfile(const std::string filename);
|
||||
bool is_final(fsmstate s); //is s a final state of fsm?
|
||||
char getc();
|
||||
bool eof();
|
||||
bool lf();
|
||||
errcode getgrammar(const std::string filename);
|
||||
bool copyset(std::set<gelem_t,comparegelem_c> & src, std::set<gelem_t,comparegelem_c> & dst);
|
||||
void genempty();
|
||||
void genfirst();
|
||||
bool getempty(std::vector<gelem_t> & src);
|
||||
std::set<gelem_t,comparegelem_c> getfirst(std::vector<gelem_t> & src);
|
||||
llelem_t getllpair(std::string nt, unsigned int ntst, unsigned char t);
|
||||
void genfollow();
|
||||
void genpredict();
|
||||
errcode genll();
|
||||
errcode genconstll();
|
||||
void genllsem();
|
||||
errcode analyze(std::string input, cName & pName);
|
||||
std::string subanalyze(const std::string input, cGram::errcode *err);
|
||||
semact getsem(const std::string input);
|
||||
void *getbstpl(cName & pName);
|
||||
void *getstrtpl(cName & pName);
|
||||
bool issub(std::string candidate,std::vector<std::string> & vec);
|
||||
void showsubs(std::vector<std::string> & vec);
|
||||
long int b36toint(std::string x);
|
||||
void * copynametpl(void * src);
|
||||
public:
|
||||
//constructor
|
||||
cGram();
|
||||
//destructor
|
||||
virtual ~cGram();
|
||||
errcode initialize(std::string gname, bool i = true);
|
||||
errcode parse(const std::string filename);
|
||||
cName *perform(const std::string input, errcode *err);
|
||||
void demangleClassName(const std::string& input, cName* retvalue, cGram::errcode& err_i);
|
||||
void showrules();
|
||||
void showempty();
|
||||
void showfirst();
|
||||
void showfollow();
|
||||
void showpredict();
|
||||
void showll();
|
||||
unsigned int isnt(std::vector<std::string> & nonterminals, std::string nonterminal);
|
||||
unsigned int ist(std::vector<unsigned char> & terminals, unsigned char terminal);
|
||||
|
||||
void resetError() {errString = "";}
|
||||
std::string errString; //string containing last error message
|
||||
bool errValid = false; //is the gParser valid? false if it has not been properly initialized yet
|
||||
bool SubAnalyzeEnabled = false; //enable substitution analysis for GCC demangler?
|
||||
void setSubAnalyze(bool x);
|
||||
|
||||
errcode generateIgrammar(const std::string inputfilename, const std::string outputname);
|
||||
std::string generatedTerminalStatic;
|
||||
|
||||
}; //class cGram
|
||||
|
||||
} // namespace demangler
|
||||
|
||||
#endif
|
|
@ -1,23 +0,0 @@
|
|||
/**
|
||||
* @file include/demangler/igrams.h
|
||||
* @brief Internal grammar list.
|
||||
* @copyright (c) 2017 Avast Software, licensed under the MIT license
|
||||
*/
|
||||
|
||||
#ifndef DEMANGLER_IGRAMS_H
|
||||
#define DEMANGLER_IGRAMS_H
|
||||
|
||||
//[igram] add internal grammar headers here
|
||||
#include "demangler/stgrammars/borlandll.h"
|
||||
#include "demangler/stgrammars/gccll.h"
|
||||
#include "demangler/stgrammars/msll.h"
|
||||
|
||||
namespace demangler {
|
||||
|
||||
bool initIgram(std::string gname, cGram* gParser);
|
||||
|
||||
void deleteIgrams(cGram* gParser);
|
||||
|
||||
} // namespace demangler
|
||||
|
||||
#endif
|
|
@ -1,25 +0,0 @@
|
|||
/**
|
||||
* @file include/demangler/stgrammars/borlandll.h
|
||||
* @brief Internal LL grammar for demangler.
|
||||
* @copyright (c) 2017 Avast Software, licensed under the MIT license
|
||||
*/
|
||||
|
||||
#ifndef DEMANGLER_STGRAMMARS_BORLANDLL_H
|
||||
#define DEMANGLER_STGRAMMARS_BORLANDLL_H
|
||||
|
||||
#include "demangler/gparser.h"
|
||||
|
||||
namespace demangler {
|
||||
|
||||
class cIgram_borlandll {
|
||||
public:
|
||||
static unsigned char terminal_static[256];
|
||||
static cGram::llelem_t llst[280][69];
|
||||
static cGram::ruleaddr_t ruleaddrs[467];
|
||||
static cGram::gelem_t ruleelements[603];
|
||||
static cGram::gelem_t root;
|
||||
cGram::igram_t getInternalGrammar();
|
||||
};
|
||||
|
||||
} // namespace demangler
|
||||
#endif
|
|
@ -1,25 +0,0 @@
|
|||
/**
|
||||
* @file include/demangler/stgrammars/gccll.h
|
||||
* @brief Internal LL grammar for demangler.
|
||||
* @copyright (c) 2017 Avast Software, licensed under the MIT license
|
||||
*/
|
||||
|
||||
#ifndef DEMANGLER_STGRAMMARS_GCCLL_H
|
||||
#define DEMANGLER_STGRAMMARS_GCCLL_H
|
||||
|
||||
#include "demangler/gparser.h"
|
||||
|
||||
namespace demangler {
|
||||
|
||||
class cIgram_gccll {
|
||||
public:
|
||||
static unsigned char terminal_static[256];
|
||||
static cGram::llelem_t llst[254][64];
|
||||
static cGram::ruleaddr_t ruleaddrs[423];
|
||||
static cGram::gelem_t ruleelements[445];
|
||||
static cGram::gelem_t root;
|
||||
cGram::igram_t getInternalGrammar();
|
||||
};
|
||||
|
||||
} // namespace demangler
|
||||
#endif
|
|
@ -1,26 +0,0 @@
|
|||
/**
|
||||
* @file include/demangler/stgrammars/msll.h
|
||||
* @brief Internal LL grammar for demangler.
|
||||
* @copyright (c) 2017 Avast Software, licensed under the MIT license
|
||||
*/
|
||||
|
||||
#ifndef DEMANGLER_STGRAMMARS_MSLL_H
|
||||
#define DEMANGLER_STGRAMMARS_MSLL_H
|
||||
|
||||
#include "demangler/gparser.h"
|
||||
|
||||
namespace demangler {
|
||||
|
||||
class cIgram_msll {
|
||||
public:
|
||||
static unsigned char terminal_static[256];
|
||||
static cGram::llelem_t llst[249][68];
|
||||
static cGram::ruleaddr_t ruleaddrs[534];
|
||||
static cGram::gelem_t ruleelements[796];
|
||||
static cGram::gelem_t root;
|
||||
cGram::igram_t getInternalGrammar();
|
||||
};
|
||||
|
||||
} // namespace demangler
|
||||
|
||||
#endif
|
|
@ -1,17 +0,0 @@
|
|||
|
||||
set(DEMANGLER_SOURCES
|
||||
demangler.cpp
|
||||
demtools.cpp
|
||||
gparser.cpp
|
||||
igrams.cpp
|
||||
stgrammars/borlandll.cpp
|
||||
stgrammars/gccll.cpp
|
||||
stgrammars/msll.cpp
|
||||
)
|
||||
|
||||
add_library(demangler STATIC ${DEMANGLER_SOURCES})
|
||||
target_include_directories(demangler PUBLIC ${PROJECT_SOURCE_DIR}/include/)
|
||||
|
||||
set_property(TARGET demangler PROPERTY CXX_STANDARD 17)
|
||||
set_property(TARGET demangler PROPERTY CXX_STANDARD_REQUIRED ON)
|
||||
disable_compiler_warnings_for_target(demangler)
|
|
@ -1,131 +0,0 @@
|
|||
/**
|
||||
* @file src/demangler/demangler.cpp
|
||||
* @brief Demangler library.
|
||||
* @copyright (c) 2017 Avast Software, licensed under the MIT license
|
||||
*/
|
||||
|
||||
|
||||
#include <iostream>
|
||||
#include <string>
|
||||
|
||||
#include "demangler/demangler.h"
|
||||
|
||||
namespace demangler {
|
||||
|
||||
/**
|
||||
* @brief Constructor of CDemangler class.
|
||||
* @param gname Grammar name. If internal grammar is used, internal grammar of this name must exist.
|
||||
* If external grammar is used file with this name must exist and it used as external grammar.
|
||||
* @param i Use internal grammar? Default setting is true. If set to false, external grammar is used.
|
||||
*/
|
||||
CDemangler::CDemangler(std::string gname, bool i):
|
||||
pGram(new cGram()),
|
||||
pName(nullptr),
|
||||
errState(cGram::ERROR_OK) {
|
||||
//if gname is empty, pGram will not be initialized (may be used for creating new internal grammars)
|
||||
if (!gname.empty()) {
|
||||
errState = pGram->initialize(gname, i);
|
||||
compiler = gname;
|
||||
}
|
||||
}
|
||||
|
||||
std::unique_ptr<CDemangler> CDemangler::createGcc(bool i)
|
||||
{
|
||||
return std::make_unique<CDemangler>("gcc", i);
|
||||
}
|
||||
|
||||
std::unique_ptr<CDemangler> CDemangler::createMs(bool i)
|
||||
{
|
||||
return std::make_unique<CDemangler>("ms", i);
|
||||
}
|
||||
|
||||
std::unique_ptr<CDemangler> CDemangler::createBorland(bool i)
|
||||
{
|
||||
return std::make_unique<CDemangler>("borland", i);
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief Destructor of CDemangler class.
|
||||
*/
|
||||
CDemangler::~CDemangler() {
|
||||
delete pGram;
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief Check if the error state of demangler is ok. Returns false if an error has ocurred during the last action.
|
||||
* @return Boolean value determining whether everything is ok.
|
||||
*/
|
||||
bool CDemangler::isOk() {
|
||||
if (errState == cGram::ERROR_OK) {
|
||||
return true;
|
||||
}
|
||||
else {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief Returns string describing the last error.
|
||||
*/
|
||||
std::string CDemangler::printError() {
|
||||
if (pGram != nullptr) {
|
||||
return pGram->errString;
|
||||
}
|
||||
else {
|
||||
return "No grammar class allocated. Cannot get error state.";
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief Reset error state.
|
||||
*/
|
||||
void CDemangler::resetError() {
|
||||
if (pGram != nullptr) {
|
||||
pGram->resetError();
|
||||
errState = cGram::ERROR_OK;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief Function which converts external grammar into internal grammar.
|
||||
* After using this function the demangler object must not be used for demangling.S
|
||||
* errState may be set if an error occurs.
|
||||
* @param inputfilename The name of the file which contains grammar rules.
|
||||
* @param outputname The name of the output grammar.
|
||||
*/
|
||||
void CDemangler::createGrammar(std::string inputfilename, std::string outputname) {
|
||||
errState = pGram->generateIgrammar(inputfilename, outputname);
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief Demangle the input string and return the demangled name class. errState may be set if an error occurs.
|
||||
* @param inputName The name to be demangled.
|
||||
* @return Pointer to a cName object containing all info anout the demangled name.
|
||||
*/
|
||||
cName *CDemangler::demangleToClass(std::string inputName) {
|
||||
return pGram->perform(inputName,&errState);
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief Demangle the input string and return the demangled name as a string. errState may be set if an error occurs.
|
||||
* @param inputName The name to be demangled.
|
||||
* @return String containing the declaration of the demangled name.
|
||||
*/
|
||||
std::string CDemangler::demangleToString(std::string inputName) {
|
||||
std::string retvalue;
|
||||
resetError();
|
||||
pName = pGram->perform(inputName,&errState);
|
||||
retvalue = pName->printall(compiler);
|
||||
delete pName;
|
||||
return retvalue;
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief Set substitution analysis manually to enabled or disabled.
|
||||
* @param x Boolean value. True means enable, false means disable.
|
||||
*/
|
||||
void CDemangler::setSubAnalyze(bool x) {
|
||||
pGram->setSubAnalyze(x);
|
||||
}
|
||||
|
||||
} // namespace demangler
|
|
@ -1,82 +0,0 @@
|
|||
/**
|
||||
* @file src/demangler/demtools.cpp
|
||||
* @brief Tools and extra functions for demangler.
|
||||
* @copyright (c) 2017 Avast Software, licensed under the MIT license
|
||||
*/
|
||||
|
||||
#include <ctime>
|
||||
#include <fstream>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
|
||||
#include "demangler/demtools.h"
|
||||
|
||||
using namespace std;
|
||||
|
||||
namespace demangler {
|
||||
|
||||
/**
|
||||
* @brief Function which finds out whether a file exists.
|
||||
* @param filename Name of the file to be checked.
|
||||
* @return Boolean value determining whether the file exists or not.
|
||||
*/
|
||||
bool fileExists(const std::string &filename) {
|
||||
ifstream ifile(filename);
|
||||
return ifile.is_open();
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief Initializes a sdate_t to default values.
|
||||
* @param x sdate_t to be initialized..
|
||||
*/
|
||||
void initSdate_t(sdate_t &x) {
|
||||
x.y = 0;
|
||||
x.m = 0;
|
||||
x.d = 0;
|
||||
x.h = 0;
|
||||
x.min = 0;
|
||||
x.s = 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief Get stuct with current date and time.
|
||||
* @return Struct with current date and time.
|
||||
*/
|
||||
sdate_t genTimeStruct() {
|
||||
sdate_t retvalue;
|
||||
initSdate_t(retvalue);
|
||||
time_t t = time(nullptr); // get time now
|
||||
struct tm * now = localtime( & t );
|
||||
//year
|
||||
retvalue.y = now->tm_year + 1900;
|
||||
//month
|
||||
retvalue.m = (now->tm_mon + 1);
|
||||
//day
|
||||
retvalue.d = now->tm_mday;
|
||||
//hour
|
||||
retvalue.h = now->tm_hour;
|
||||
//minute
|
||||
retvalue.min = now->tm_min;
|
||||
//second
|
||||
retvalue.s = now->tm_sec;
|
||||
return retvalue;
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief Replaces strings "tobereplaced" in source with "replacement".
|
||||
* @param source Source string.
|
||||
* @param tobereplaced Substring which will be searched for and all of its instances will be replaced.
|
||||
* @param replacement The replacement string.
|
||||
*/
|
||||
void xreplace(string &source, const string &tobereplaced, const string &replacement) {
|
||||
std::size_t lastfound = 0;
|
||||
if (tobereplaced != "") {
|
||||
while (source.find(tobereplaced,lastfound) != source.npos) {
|
||||
lastfound = source.find(tobereplaced,lastfound);
|
||||
source.replace(source.find(tobereplaced,lastfound),tobereplaced.length(),replacement);
|
||||
lastfound += replacement.length();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
} // namespace demangler
|
|
@ -1,467 +0,0 @@
|
|||
<mangled-name> ::= <template-prefix> @ <qualified-name> <sem-unq2f> <function-section> <sem-end>
|
||||
<template-prefix> ::=
|
||||
<template-section> ::= % <name-element> $ t <sem-begintempl> <sem-beginbsub> <type> <type-more-template> %
|
||||
<qualified-name> ::= <name-element> <name-element-more>
|
||||
<name-element-more> ::=
|
||||
<name-element-more> ::= @ <name-element> <name-element-more>
|
||||
<name-element> ::= @ <name-element> #double @ for __linksys__ - ignore that for now and just use qualified name
|
||||
<name-element> ::= $ <op>
|
||||
<name-element> ::= <template-section>
|
||||
<name-element> ::= <name-char> <name-char-more>
|
||||
<name-char-more> ::= <sem-storename> #no more characters in name, store the name
|
||||
<name-char-more> ::= <name-char> <name-char-more>
|
||||
<name-char> ::= <sem-addchartoname> _
|
||||
<name-char> ::= <sem-addchartoname> a
|
||||
<name-char> ::= <sem-addchartoname> b
|
||||
<name-char> ::= <sem-addchartoname> c
|
||||
<name-char> ::= <sem-addchartoname> d
|
||||
<name-char> ::= <sem-addchartoname> e
|
||||
<name-char> ::= <sem-addchartoname> f
|
||||
<name-char> ::= <sem-addchartoname> g
|
||||
<name-char> ::= <sem-addchartoname> h
|
||||
<name-char> ::= <sem-addchartoname> i
|
||||
<name-char> ::= <sem-addchartoname> j
|
||||
<name-char> ::= <sem-addchartoname> k
|
||||
<name-char> ::= <sem-addchartoname> l
|
||||
<name-char> ::= <sem-addchartoname> m
|
||||
<name-char> ::= <sem-addchartoname> n
|
||||
<name-char> ::= <sem-addchartoname> o
|
||||
<name-char> ::= <sem-addchartoname> p
|
||||
<name-char> ::= <sem-addchartoname> q
|
||||
<name-char> ::= <sem-addchartoname> r
|
||||
<name-char> ::= <sem-addchartoname> s
|
||||
<name-char> ::= <sem-addchartoname> t
|
||||
<name-char> ::= <sem-addchartoname> u
|
||||
<name-char> ::= <sem-addchartoname> v
|
||||
<name-char> ::= <sem-addchartoname> w
|
||||
<name-char> ::= <sem-addchartoname> x
|
||||
<name-char> ::= <sem-addchartoname> y
|
||||
<name-char> ::= <sem-addchartoname> z
|
||||
<name-char> ::= <sem-addchartoname> A
|
||||
<name-char> ::= <sem-addchartoname> B
|
||||
<name-char> ::= <sem-addchartoname> C
|
||||
<name-char> ::= <sem-addchartoname> D
|
||||
<name-char> ::= <sem-addchartoname> E
|
||||
<name-char> ::= <sem-addchartoname> F
|
||||
<name-char> ::= <sem-addchartoname> G
|
||||
<name-char> ::= <sem-addchartoname> H
|
||||
<name-char> ::= <sem-addchartoname> I
|
||||
<name-char> ::= <sem-addchartoname> J
|
||||
<name-char> ::= <sem-addchartoname> K
|
||||
<name-char> ::= <sem-addchartoname> L
|
||||
<name-char> ::= <sem-addchartoname> M
|
||||
<name-char> ::= <sem-addchartoname> N
|
||||
<name-char> ::= <sem-addchartoname> O
|
||||
<name-char> ::= <sem-addchartoname> P
|
||||
<name-char> ::= <sem-addchartoname> Q
|
||||
<name-char> ::= <sem-addchartoname> R
|
||||
<name-char> ::= <sem-addchartoname> S
|
||||
<name-char> ::= <sem-addchartoname> T
|
||||
<name-char> ::= <sem-addchartoname> U
|
||||
<name-char> ::= <sem-addchartoname> V
|
||||
<name-char> ::= <sem-addchartoname> W
|
||||
<name-char> ::= <sem-addchartoname> X
|
||||
<name-char> ::= <sem-addchartoname> Y
|
||||
<name-char> ::= <sem-addchartoname> Z
|
||||
<name-char> ::= <sem-addchartoname> 0
|
||||
<name-char> ::= <sem-addchartoname> 1
|
||||
<name-char> ::= <sem-addchartoname> 2
|
||||
<name-char> ::= <sem-addchartoname> 3
|
||||
<name-char> ::= <sem-addchartoname> 4
|
||||
<name-char> ::= <sem-addchartoname> 5
|
||||
<name-char> ::= <sem-addchartoname> 6
|
||||
<name-char> ::= <sem-addchartoname> 7
|
||||
<name-char> ::= <sem-addchartoname> 8
|
||||
<name-char> ::= <sem-addchartoname> 9
|
||||
<function-section> ::= <sem-setnamex>
|
||||
<function-section> ::= $ <const-vol> q <calling-convention> <parameters>
|
||||
<const-vol> ::=
|
||||
<const-vol> ::= <sem-addmconst> x <const-vol>
|
||||
<const-vol> ::= <sem-addmvol> w <const-vol>
|
||||
<calling-convention> ::=
|
||||
<calling-convention> ::= <sem-setfpascal> Q
|
||||
<calling-convention> ::= q <calling-convention-q>
|
||||
<calling-convention-q> ::= <sem-setffortran> f
|
||||
<calling-convention-q> ::= <sem-setfstdcall> s
|
||||
<calling-convention-q> ::= <sem-setffastcall> r
|
||||
<calling-convention-q> ::= <sem-setfinterrupt> i
|
||||
<parameters> ::= <sem-beginbsub> <type> <type-more>
|
||||
<type-more> ::= <sem-par2f>
|
||||
<type-more> ::= <sem-storepar> <sem-beginbsub> <type> <type-more>
|
||||
<type-more-template> ::= <sem-storetemplate>
|
||||
<type-more-template> ::= <sem-storetemparg> <sem-beginbsub> <type> <type-more-template>
|
||||
<type> ::= <sem-settypev> v #void
|
||||
<type> ::= <sem-settypec> c #char
|
||||
<type> ::= <sem-settypes> s #short int
|
||||
<type> ::= <sem-settypei> i #int
|
||||
<type> ::= <sem-settypex> j #__int64
|
||||
<type> ::= <sem-settypel> l #long int
|
||||
<type> ::= <sem-settypew> b #wchar_t
|
||||
<type> ::= <sem-settypef> f #float
|
||||
<type> ::= <sem-settyped> d #double
|
||||
<type> ::= <sem-settypee> g #long double
|
||||
<type> ::= <sem-settypeb> o #bool
|
||||
<type> ::= z <type-z>
|
||||
<type> ::= u <type-u>
|
||||
<type> ::= x <sem-setconst> <type>
|
||||
<type> ::= p <sem-setptr> <type>
|
||||
<type> ::= w <sem-setvolatile> <type>
|
||||
<type> ::= r <sem-setref> <type>
|
||||
<type> ::= t <typesub>
|
||||
<type> ::= a <array-number> $ <type>
|
||||
<array-number> ::= <sem-borlandarr> <number>
|
||||
<type> ::= <source-name>
|
||||
<type-z> ::= <sem-settypea> c #signed char
|
||||
<type-u> ::= <sem-settypeh> c #unsigned char
|
||||
<type-u> ::= <sem-settypet> s #unsigned short int
|
||||
<type-u> ::= <sem-settypej> i #unsigned int
|
||||
<type-u> ::= <sem-settypem> l #unsigned long int
|
||||
<typesub> ::= <sem-loadborlandsub> 1
|
||||
<typesub> ::= <sem-loadborlandsub> 2
|
||||
<typesub> ::= <sem-loadborlandsub> 3
|
||||
<typesub> ::= <sem-loadborlandsub> 4
|
||||
<typesub> ::= <sem-loadborlandsub> 5
|
||||
<typesub> ::= <sem-loadborlandsub> 6
|
||||
<typesub> ::= <sem-loadborlandsub> 7
|
||||
<typesub> ::= <sem-loadborlandsub> 8
|
||||
<typesub> ::= <sem-loadborlandsub> 9
|
||||
<typesub> ::= <sem-loadborlandsub> a
|
||||
<typesub> ::= <sem-loadborlandsub> b
|
||||
<typesub> ::= <sem-loadborlandsub> c
|
||||
<typesub> ::= <sem-loadborlandsub> d
|
||||
<typesub> ::= <sem-loadborlandsub> e
|
||||
<typesub> ::= <sem-loadborlandsub> f
|
||||
<typesub> ::= <sem-loadborlandsub> g
|
||||
<typesub> ::= <sem-loadborlandsub> h
|
||||
<typesub> ::= <sem-loadborlandsub> i
|
||||
<typesub> ::= <sem-loadborlandsub> j
|
||||
<typesub> ::= <sem-loadborlandsub> k
|
||||
<typesub> ::= <sem-loadborlandsub> l
|
||||
<typesub> ::= <sem-loadborlandsub> m
|
||||
<typesub> ::= <sem-loadborlandsub> n
|
||||
<typesub> ::= <sem-loadborlandsub> o
|
||||
<typesub> ::= <sem-loadborlandsub> p
|
||||
<typesub> ::= <sem-loadborlandsub> q
|
||||
<typesub> ::= <sem-loadborlandsub> r
|
||||
<typesub> ::= <sem-loadborlandsub> s
|
||||
<typesub> ::= <sem-loadborlandsub> t
|
||||
<typesub> ::= <sem-loadborlandsub> u
|
||||
<typesub> ::= <sem-loadborlandsub> v
|
||||
<typesub> ::= <sem-loadborlandsub> w
|
||||
<typesub> ::= <sem-loadborlandsub> x
|
||||
<typesub> ::= <sem-loadborlandsub> y
|
||||
<typesub> ::= <sem-loadborlandsub> z
|
||||
<source-name> ::= <source-number>
|
||||
<source-number> ::= <sem-borlandid> <number> <qualified-name> <sem-unq2p> |
|
||||
<number> ::= 0
|
||||
<number> ::= 1
|
||||
<number> ::= 2
|
||||
<number> ::= 3
|
||||
<number> ::= 4
|
||||
<number> ::= 5
|
||||
<number> ::= 6
|
||||
<number> ::= 7
|
||||
<number> ::= 8
|
||||
<number> ::= 9
|
||||
<op> ::= b <op-b>
|
||||
<op-b> ::= a <op-ba>
|
||||
<op-ba> ::= d <op-bad>
|
||||
<op-bad> ::= <sem-setnameo> <sem-setoppl> d #operator +
|
||||
<op-bad> ::= <sem-setnameo> <sem-setopad> r #operator & (unary)
|
||||
<op-ba> ::= n <op-ban>
|
||||
<op-ban> ::= <sem-setnameo> <sem-setopan> d #operator &
|
||||
<op-ba> ::= r <op-bar>
|
||||
<op-bar> ::= o <op-baro>
|
||||
<op-baro> ::= <sem-setnameo> <sem-setoppt> w #operator ->
|
||||
<op-bar> ::= w <op-barw>
|
||||
<op-barw> ::= <sem-setnameo> <sem-setoppm> m #operator ->*
|
||||
<op-ba> ::= s <op-bas>
|
||||
<op-bas> ::= <sem-setnameo> <sem-setopass> g #operator =
|
||||
<op-b> ::= c <op-bc>
|
||||
<op-bc> ::= a <op-bca>
|
||||
<op-bca> ::= l <op-bcal>
|
||||
<op-bcal> ::= <sem-setnameo> <sem-setopcl> l #operator ()
|
||||
<op-bc> ::= m <op-bcm>
|
||||
<op-bcm> ::= <sem-setnameo> <sem-setopco> p #operator ~
|
||||
<op-bc> ::= o <op-bco>
|
||||
<op-bco> ::= m <op-bcom>
|
||||
<op-bcom> ::= <sem-setnameo> <sem-setopcm> a #operator ,
|
||||
<op-bc> ::= t <op-bct>
|
||||
<op-bct> ::= <sem-setnamec> r #constructor
|
||||
<op-b> ::= d <op-bd>
|
||||
<op-bd> ::= e <op-bde>
|
||||
<op-bde> ::= <sem-setnameo> <sem-setopmm> c #operator --
|
||||
<op-bde> ::= l <op-bdel>
|
||||
<op-bdel> ::= <sem-setnameo> <sem-setopdl> e #operator delete
|
||||
<op-bd> ::= i <op-bdi>
|
||||
<op-bdi> ::= <sem-setnameo> <sem-setopdv> v #operator /
|
||||
<op-bd> ::= l <op-bdl>
|
||||
<op-bdl> ::= <sem-setnameo> <sem-setopda> a #operator delete[]
|
||||
<op-bd> ::= t <op-bdt>
|
||||
<op-bdt> ::= <sem-setnamed> r #destructor
|
||||
<op-b> ::= e <op-be>
|
||||
<op-be> ::= q <op-beq>
|
||||
<op-beq> ::= <sem-setnameo> <sem-setopeq> l #operator ==
|
||||
<op-b> ::= g <op-bg>
|
||||
<op-bg> ::= e <op-bge>
|
||||
<op-bge> ::= <sem-setnameo> <sem-setopge> q #operator >=
|
||||
<op-bg> ::= t <op-bgt>
|
||||
<op-bgt> ::= <sem-setnameo> <sem-setopgt> r #operator >
|
||||
<op-b> ::= i <op-bi>
|
||||
<op-bi> ::= n <op-bin>
|
||||
<op-bin> ::= <sem-setnameo> <sem-setoppp> c #operator ++
|
||||
<op-bin> ::= <sem-setnameo> <sem-setopde> d #operator * (unary)
|
||||
<op-b> ::= l <op-bl>
|
||||
<op-bl> ::= a <op-bla>
|
||||
<op-bla> ::= n <op-blan>
|
||||
<op-blan> ::= <sem-setnameo> <sem-setopaa> d #operator &&
|
||||
<op-bl> ::= e <op-ble>
|
||||
<op-ble> ::= <sem-setnameo> <sem-setople> q #operator <=
|
||||
<op-bl> ::= o <op-blo>
|
||||
<op-blo> ::= <sem-setnameo> <sem-setopoo> r #operator ||
|
||||
<op-bl> ::= s <op-bls>
|
||||
<op-bls> ::= <sem-setnameo> <sem-setopls> h #operator <<
|
||||
<op-bls> ::= <sem-setnameo> <sem-setoplt> s #operator <
|
||||
<op-b> ::= m <op-bm>
|
||||
<op-bm> ::= o <op-bmo>
|
||||
<op-bmo> ::= <sem-setnameo> <sem-setoprm> d #operator %
|
||||
<op-bm> ::= u <op-bmu>
|
||||
<op-bmu> ::= <sem-setnameo> <sem-setopml> l #operator *
|
||||
<op-b> ::= n <op-bn>
|
||||
<op-bn> ::= e <op-bne>
|
||||
<op-bne> ::= <sem-setnameo> <sem-setopne> q #operator !=
|
||||
<op-bne> ::= <sem-setnameo> <sem-setopnw> w #operator new
|
||||
<op-bn> ::= o <op-bno>
|
||||
<op-bno> ::= <sem-setnameo> <sem-setopnt> t #operator !
|
||||
<op-bn> ::= w <op-bnw>
|
||||
<op-bnw> ::= <sem-setnameo> <sem-setopna> a #operator new[]
|
||||
<op-b> ::= o <op-bo>
|
||||
<op-bo> ::= <sem-setnameo> <sem-setopor> r #operator |
|
||||
<op-b> ::= r <op-br>
|
||||
<op-br> ::= a <op-bra>
|
||||
<op-bra> ::= n <op-bran>
|
||||
<op-bran> ::= <sem-setnameo> <sem-setopann> d #operator &=
|
||||
<op-br> ::= d <op-brd>
|
||||
<op-brd> ::= i <op-brdi>
|
||||
<op-brdi> ::= <sem-setnameo> <sem-setopdvv> v #operator /=
|
||||
<op-br> ::= l <op-brl>
|
||||
<op-brl> ::= s <op-brls>
|
||||
<op-brls> ::= <sem-setnameo> <sem-setoplss> h #operator <<=
|
||||
<op-br> ::= m <op-brm>
|
||||
<op-brm> ::= i <op-brmi>
|
||||
<op-brmi> ::= <sem-setnameo> <sem-setopmii> n #operator -=
|
||||
<op-brm> ::= o <op-brmo>
|
||||
<op-brmo> ::= <sem-setnameo> <sem-setoprmm> d #operator %=
|
||||
<op-brm> ::= u <op-brmu>
|
||||
<op-brmu> ::= <sem-setnameo> <sem-setopmll> l #operator *=
|
||||
<op-br> ::= o <op-bro>
|
||||
<op-bro> ::= <sem-setnameo> <sem-setoporr> r #operator |=
|
||||
<op-br> ::= p <op-brp>
|
||||
<op-brp> ::= l <op-brpl>
|
||||
<op-brpl> ::= <sem-setnameo> <sem-setoppll> u #operator +=
|
||||
<op-br> ::= r <op-brr>
|
||||
<op-brr> ::= s <op-brrs>
|
||||
<op-brrs> ::= <sem-setnameo> <sem-setoprss> h #operator >>=
|
||||
<op-br> ::= s <op-brs>
|
||||
<op-brs> ::= <sem-setnameo> <sem-setoprs> h #operator >>
|
||||
<op-br> ::= x <op-brx>
|
||||
<op-brx> ::= o <op-brxo>
|
||||
<op-brxo> ::= <sem-setnameo> <sem-setopeoo> r #operator ^=
|
||||
<op-b> ::= s <op-bs>
|
||||
<op-bs> ::= u <op-bsu>
|
||||
<op-bsu> ::= b <op-bsub>
|
||||
<op-bsub> ::= <sem-setnameo> <sem-setopmi> #operator -
|
||||
<op-bsub> ::= <sem-setnameo> <sem-setopix> s #operator []
|
||||
<op-b> ::= x <op-bx>
|
||||
<op-bx> ::= o <op-bxo>
|
||||
<op-bxo> ::= <sem-setnameo> <sem-setopeo> r #operator ^
|
||||
<sem-addchartoname> ::=
|
||||
<sem-storename> ::=
|
||||
<sem-loadid> ::=
|
||||
<sem-loadarr> ::=
|
||||
<sem-ssno> ::=
|
||||
<sem-ssnest> ::=
|
||||
<sem-stunq> ::=
|
||||
<sem-loadtsub> ::=
|
||||
<sem-type2expr> ::=
|
||||
<sem-exprval> ::=
|
||||
<sem-beginexpr> ::=
|
||||
<sem-storeexpr> ::=
|
||||
<sem-copyexpr> ::=
|
||||
<sem-storepar> ::=
|
||||
<sem-begintempl> ::=
|
||||
<sem-skiptempl> ::=
|
||||
<sem-storetemparg> ::=
|
||||
<sem-storetemplate> ::=
|
||||
<sem-setnametf> ::=
|
||||
<sem-par2f> ::=
|
||||
<sem-unq2f> ::=
|
||||
<sem-unq2p> ::=
|
||||
<sem-setnamex> ::=
|
||||
<sem-setnameo> ::=
|
||||
<sem-par2spec> ::=
|
||||
<sem-par2ret> ::=
|
||||
<sem-settypev> ::=
|
||||
<sem-settypew> ::=
|
||||
<sem-settypeb> ::=
|
||||
<sem-settypec> ::=
|
||||
<sem-settypea> ::=
|
||||
<sem-settypeh> ::=
|
||||
<sem-settypes> ::=
|
||||
<sem-settypet> ::=
|
||||
<sem-settypei> ::=
|
||||
<sem-settypej> ::=
|
||||
<sem-settypel> ::=
|
||||
<sem-settypem> ::=
|
||||
<sem-settypex> ::=
|
||||
<sem-settypey> ::=
|
||||
<sem-settypen> ::=
|
||||
<sem-settypeo> ::=
|
||||
<sem-settypef> ::=
|
||||
<sem-settyped> ::=
|
||||
<sem-settypee> ::=
|
||||
<sem-settypeg> ::=
|
||||
<sem-settypez> ::=
|
||||
<sem-setrestrict> ::=
|
||||
<sem-setvolatile> ::=
|
||||
<sem-setconst> ::=
|
||||
<sem-setptr> ::=
|
||||
<sem-setref> ::=
|
||||
<sem-setrval> ::=
|
||||
<sem-setcpair> ::=
|
||||
<sem-setim> ::=
|
||||
<sem-substd> ::=
|
||||
<sem-subalc> ::=
|
||||
<sem-substr> ::=
|
||||
<sem-substrs> ::=
|
||||
<sem-subistr> ::=
|
||||
<sem-subostr> ::=
|
||||
<sem-subiostr> ::=
|
||||
<sem-loadsub> ::=
|
||||
<sem-setnamec> ::=
|
||||
<sem-setnamed> ::=
|
||||
<sem-setopnw> ::=
|
||||
<sem-setopna> ::=
|
||||
<sem-setopdl> ::=
|
||||
<sem-setopda> ::=
|
||||
<sem-setopps> ::=
|
||||
<sem-setopng> ::=
|
||||
<sem-setopad> ::=
|
||||
<sem-setopde> ::=
|
||||
<sem-setopco> ::=
|
||||
<sem-setoppl> ::=
|
||||
<sem-setopmi> ::=
|
||||
<sem-setopml> ::=
|
||||
<sem-setopdv> ::=
|
||||
<sem-setoprm> ::=
|
||||
<sem-setopan> ::=
|
||||
<sem-setopor> ::=
|
||||
<sem-setopeo> ::=
|
||||
<sem-setopass> ::=
|
||||
<sem-setoppll> ::=
|
||||
<sem-setopmii> ::=
|
||||
<sem-setopmll> ::=
|
||||
<sem-setopdvv> ::=
|
||||
<sem-setoprmm> ::=
|
||||
<sem-setopann> ::=
|
||||
<sem-setoporr> ::=
|
||||
<sem-setopeoo> ::=
|
||||
<sem-setopls> ::=
|
||||
<sem-setoprs> ::=
|
||||
<sem-setoplss> ::=
|
||||
<sem-setoprss> ::=
|
||||
<sem-setopeq> ::=
|
||||
<sem-setopne> ::=
|
||||
<sem-setoplt> ::=
|
||||
<sem-setopgt> ::=
|
||||
<sem-setople> ::=
|
||||
<sem-setopnt> ::=
|
||||
<sem-setopaa> ::=
|
||||
<sem-setopoo> ::=
|
||||
<sem-setoppp> ::=
|
||||
<sem-setopmm> ::=
|
||||
<sem-setopcm> ::=
|
||||
<sem-setoppm> ::=
|
||||
<sem-setoppt> ::=
|
||||
<sem-setopcl> ::=
|
||||
<sem-setopix> ::=
|
||||
<sem-setopge> ::=
|
||||
<sem-setopqu> ::=
|
||||
<sem-setopst> ::=
|
||||
<sem-setopsz> ::=
|
||||
<sem-setopat> ::=
|
||||
<sem-setopaz> ::=
|
||||
<sem-setopcv> ::=
|
||||
<sem-setopxx> ::=
|
||||
<sem-setnamef> ::=
|
||||
<sem-setnamevt> ::=
|
||||
<sem-reversename> ::=
|
||||
<sem-setprivate> ::=
|
||||
<sem-setpublic> ::=
|
||||
<sem-setprotected> ::=
|
||||
<sem-setfcdecl> ::=
|
||||
<sem-setfpascal> ::=
|
||||
<sem-setffortran> ::=
|
||||
<sem-setfthiscall> ::=
|
||||
<sem-setfstdcall> ::=
|
||||
<sem-setffastcall> ::=
|
||||
<sem-setfinterrupt> ::=
|
||||
<sem-setunion> ::=
|
||||
<sem-setstruct> ::=
|
||||
<sem-setclass> ::=
|
||||
<sem-setenum> ::=
|
||||
<sem-setstatic> ::=
|
||||
<sem-setvirtual> ::=
|
||||
<sem-stclconst> ::=
|
||||
<sem-stclvol> ::=
|
||||
<sem-stclfar> ::=
|
||||
<sem-stclhuge> ::=
|
||||
<sem-savenamesub> ::=
|
||||
<sem-loadnamesub> ::=
|
||||
<sem-mstemplsub> ::=
|
||||
<sem-setnamer0> ::=
|
||||
<sem-setnamer1> ::=
|
||||
<sem-setnamer2> ::=
|
||||
<sem-setnamer3> ::=
|
||||
<sem-setnamer4> ::=
|
||||
<sem-setname_a> ::=
|
||||
<sem-setname_b> ::=
|
||||
<sem-setname_c> ::=
|
||||
<sem-setname_d> ::=
|
||||
<sem-setname_e> ::=
|
||||
<sem-setname_f> ::=
|
||||
<sem-setname_g> ::=
|
||||
<sem-setname_h> ::=
|
||||
<sem-setname_i> ::=
|
||||
<sem-setname_j> ::=
|
||||
<sem-setname_k> ::=
|
||||
<sem-setname_l> ::=
|
||||
<sem-setname_m> ::=
|
||||
<sem-setname_n> ::=
|
||||
<sem-setname_o> ::=
|
||||
<sem-setname_p> ::=
|
||||
<sem-setname_q> ::=
|
||||
<sem-setname_r> ::=
|
||||
<sem-setname_s> ::=
|
||||
<sem-setname_t> ::=
|
||||
<sem-setname_u> ::=
|
||||
<sem-setname_v> ::=
|
||||
<sem-setname_w> ::=
|
||||
<sem-setname_x> ::=
|
||||
<sem-setname_y> ::=
|
||||
<sem-setname_z> ::=
|
||||
<sem-templ2tftpl> ::=
|
||||
<sem-beginbsub> ::= #begin built-in substitution
|
||||
<sem-loadbsub> ::=
|
||||
<sem-addmconst> ::=
|
||||
<sem-addmvol> ::=
|
||||
<sem-addmfar> ::=
|
||||
<sem-addmhuge> ::=
|
||||
<sem-loadmsnum> ::=
|
||||
<sem-numtorttibcd> ::=
|
||||
<sem-numtotype> ::=
|
||||
<sem-normalizeparname> ::=
|
||||
<sem-borlandid> ::=
|
||||
<sem-loadborlandsub> ::=
|
||||
<sem-borlandarr> ::=
|
||||
<sem-end> ::=
|
|
@ -1,423 +0,0 @@
|
|||
<mangled-name> ::= _ <mangled-name2>
|
||||
<mangled-name2> ::= <mangled-name3> <sem-end>
|
||||
<mangled-name2> ::= _ <mangled-name3> <sem-end>
|
||||
<mangled-name3> ::= Z <encoding>
|
||||
<encoding> ::= <name> <bare-function-type>
|
||||
<name> ::= <nested-name>
|
||||
<name> ::= <source-name> <template-args>
|
||||
<name> ::= S <name-sub> #deciding rule
|
||||
<name-sub> ::= <sem-ssno> <substitution2-t> <unqualified-name>
|
||||
<name-sub> ::= <sem-ssno> <substitution2> <template-args>
|
||||
<template-args> ::= <sem-skiptempl>
|
||||
<template-args> ::= <sem-begintempl> I <template-arg> <template-arg-more> E
|
||||
<template-args-nostore> ::= <sem-skiptempl>
|
||||
<template-args-nostore> ::= <sem-begintempl> I <template-arg-nostore> <template-arg-nostore-more> E
|
||||
<template-arg-more> ::= <sem-storetemparg> <template-arg> <template-arg-more>
|
||||
<template-arg-more> ::= <sem-storetemplate>
|
||||
<template-arg> ::= <type>
|
||||
<template-arg> ::= <expr-primary>
|
||||
<template-arg-nostore> ::= <type>
|
||||
<template-arg-nostore> ::= <expr-primary>
|
||||
<template-arg-nostore-more> ::= <sem-storetemparg> <template-arg> <template-arg-more>
|
||||
<template-arg-nostore-more> ::= <sem-templ2tftpl>
|
||||
<template-param> ::= T <template-param2>
|
||||
<template-param2> ::= <sem-loadtsub> _
|
||||
<template-param2> ::= <sem-loadtsub> <number> _ #<unscoped-name> ::= <unqualified-name> #<unscoped-name> ::= St <unqualified-name> # unused, but may be useful in the future
|
||||
<nested-name> ::= <sem-ssnest> N <CV-qualifiers> <unqualified-name> <unqualified-name-more> E
|
||||
<prefix> ::=
|
||||
<prefix> ::= <substitution>
|
||||
<prefix> ::= <template-param>
|
||||
<unqualified-function-name> ::= <unqualified-name>
|
||||
<unqualified-function-name> ::= <ctor-dtor-name> <template-args-nostore>
|
||||
<unqualified-function-name> ::= <operator-name-setname>
|
||||
<operator-name-setname> ::= <sem-setnameo> <operator-name> <template-args>
|
||||
<operator-name-setname> ::= <sem-setnameo> <operator-name-cv>
|
||||
<unqualified-name> ::= <source-name> <template-args>
|
||||
<unqualified-name> ::= <substitution> <template-args>
|
||||
<unqualified-name-more> ::= <unqualified-function-name> <unqualified-name-more>
|
||||
<unqualified-name-more> ::=
|
||||
<source-name> ::= <source-number>
|
||||
<source-number> ::= <sem-loadid> <number>
|
||||
<number> ::= 0
|
||||
<number> ::= 1
|
||||
<number> ::= 2
|
||||
<number> ::= 3
|
||||
<number> ::= 4
|
||||
<number> ::= 5
|
||||
<number> ::= 6
|
||||
<number> ::= 7
|
||||
<number> ::= 8
|
||||
<number> ::= 9
|
||||
<ctor-dtor-name> ::= <sem-setnamec> C <ctor>
|
||||
<ctor> ::= 1 # complete object constructor
|
||||
<ctor> ::= 2 # base object constructor
|
||||
<ctor> ::= 3 # complete object allocating constructor
|
||||
<ctor-dtor-name> ::= <sem-setnamed> D <dtor>
|
||||
<dtor> ::= 0 # deleting destructor
|
||||
<dtor> ::= 1 # complete object destructor
|
||||
<dtor> ::= 2 # base object destructor
|
||||
<CV-qualifiers> ::= <r> <V> <K>
|
||||
<r> ::= <sem-setrestrict> r # restrict
|
||||
<r> ::=
|
||||
<V> ::= <sem-setvolatile> V # volatile
|
||||
<V> ::=
|
||||
<K> ::= <sem-setconst> K # const
|
||||
<K> ::=
|
||||
<bare-function-type> ::= <sem-unq2f> <bare-function-type2>
|
||||
<bare-function-type2> ::= <type> <another-type> <sem-par2f>
|
||||
<bare-function-type2> ::= <sem-setnamex>
|
||||
<another-type> ::= <sem-storepar> <type> <another-type>
|
||||
<another-type> ::=
|
||||
<type> ::= <type-qualifier> <type2>
|
||||
<type-qualifier> ::=
|
||||
<type-qualifier> ::= <sem-setrestrict> r <type-qualifier>
|
||||
<type-qualifier> ::= <sem-setvolatile> V <type-qualifier>
|
||||
<type-qualifier> ::= <sem-setconst> K <type-qualifier>
|
||||
<type-qualifier> ::= <sem-setptr> P <type-qualifier>
|
||||
<type-qualifier> ::= <sem-setref> R <type-qualifier>
|
||||
<type-qualifier> ::= <sem-setrval> O <type-qualifier>
|
||||
<type-qualifier> ::= <sem-setcpair> C <type-qualifier>
|
||||
<type-qualifier> ::= <sem-setim> G <type-qualifier>
|
||||
<type2> ::= <template-param>
|
||||
<type2> ::= <builtin-type>
|
||||
<type2> ::= <class-enum-type>
|
||||
<type2> ::= <array-type>
|
||||
<array-type> ::= A <array-number> _ <type>
|
||||
<array-number> ::= <sem-loadarr> <number>
|
||||
<class-enum-type> ::= <name>
|
||||
<builtin-type> ::= <sem-settypev> v # void
|
||||
<builtin-type> ::= <sem-settypew> w # wchar_t
|
||||
<builtin-type> ::= <sem-settypeb> b # bool
|
||||
<builtin-type> ::= <sem-settypec> c # char
|
||||
<builtin-type> ::= <sem-settypea> a # signed char
|
||||
<builtin-type> ::= <sem-settypeh> h # unsigned char
|
||||
<builtin-type> ::= <sem-settypes> s # short
|
||||
<builtin-type> ::= <sem-settypet> t # unsigned short
|
||||
<builtin-type> ::= <sem-settypei> i # int
|
||||
<builtin-type> ::= <sem-settypej> j # unsigned int
|
||||
<builtin-type> ::= <sem-settypel> l # long
|
||||
<builtin-type> ::= <sem-settypem> m # unsigned long
|
||||
<builtin-type> ::= <sem-settypex> x # long long, __int64
|
||||
<builtin-type> ::= <sem-settypey> y # unsigned long long, __int64
|
||||
<builtin-type> ::= <sem-settypen> n # __int128
|
||||
<builtin-type> ::= <sem-settypeo> o # unsigned __int128
|
||||
<builtin-type> ::= <sem-settypef> f # float
|
||||
<builtin-type> ::= <sem-settyped> d # double
|
||||
<builtin-type> ::= <sem-settypee> e # long double, __float80
|
||||
<builtin-type> ::= <sem-settypeg> g # __float128
|
||||
<builtin-type> ::= <sem-settypez> z # ellipsis
|
||||
<builtin-type> ::= D <builtin-type2>
|
||||
<builtin-type2> ::= d # IEEE 754r decimal floating point (64 bits)
|
||||
<builtin-type2> ::= e # IEEE 754r decimal floating point (128 bits)
|
||||
<builtin-type2> ::= f # IEEE 754r decimal floating point (32 bits)
|
||||
<builtin-type2> ::= h # IEEE 754r half-precision floating point (16 bits)
|
||||
<builtin-type2> ::= i # char32_t
|
||||
<builtin-type2> ::= s # char16_t
|
||||
<builtin-type2> ::= a # auto (in dependent new-expressions)
|
||||
<builtin-type2> ::= n # std::nullptr_t (i.e., decltype(nullptr))
|
||||
<substitution> ::= S <subst>
|
||||
<subst> ::= <substitution2-t> # separating St
|
||||
<subst> ::= <substitution2>
|
||||
<substitution2> ::= <seq-id> _
|
||||
<substitution2> ::= <sem-loadsub> _
|
||||
<seq-id> ::= <sem-loadsub> 0
|
||||
<seq-id> ::= <sem-loadsub> 1
|
||||
<seq-id> ::= <sem-loadsub> 2
|
||||
<seq-id> ::= <sem-loadsub> 3
|
||||
<seq-id> ::= <sem-loadsub> 4
|
||||
<seq-id> ::= <sem-loadsub> 5
|
||||
<seq-id> ::= <sem-loadsub> 6
|
||||
<seq-id> ::= <sem-loadsub> 7
|
||||
<seq-id> ::= <sem-loadsub> 8
|
||||
<seq-id> ::= <sem-loadsub> 9
|
||||
<seq-id> ::= <sem-loadsub> A
|
||||
<seq-id> ::= <sem-loadsub> B
|
||||
<seq-id> ::= <sem-loadsub> C
|
||||
<seq-id> ::= <sem-loadsub> D
|
||||
<seq-id> ::= <sem-loadsub> E
|
||||
<seq-id> ::= <sem-loadsub> F
|
||||
<seq-id> ::= <sem-loadsub> G
|
||||
<seq-id> ::= <sem-loadsub> H
|
||||
<seq-id> ::= <sem-loadsub> I
|
||||
<seq-id> ::= <sem-loadsub> J
|
||||
<seq-id> ::= <sem-loadsub> K
|
||||
<seq-id> ::= <sem-loadsub> L
|
||||
<seq-id> ::= <sem-loadsub> M
|
||||
<seq-id> ::= <sem-loadsub> N
|
||||
<seq-id> ::= <sem-loadsub> O
|
||||
<seq-id> ::= <sem-loadsub> P
|
||||
<seq-id> ::= <sem-loadsub> Q
|
||||
<seq-id> ::= <sem-loadsub> R
|
||||
<seq-id> ::= <sem-loadsub> S
|
||||
<seq-id> ::= <sem-loadsub> T
|
||||
<seq-id> ::= <sem-loadsub> U
|
||||
<seq-id> ::= <sem-loadsub> V
|
||||
<seq-id> ::= <sem-loadsub> W
|
||||
<seq-id> ::= <sem-loadsub> X
|
||||
<seq-id> ::= <sem-loadsub> Y
|
||||
<seq-id> ::= <sem-loadsub> Z
|
||||
<substitution2-t> ::= <sem-substd> t # ::std::
|
||||
<substitution2> ::= <sem-subalc> a # ::std::allocator
|
||||
<substitution2> ::= <sem-substr> b # ::std::basic_string
|
||||
<substitution2> ::= <sem-substrs> s # ::std::basic_string<char,::std::char_traits<char>,::std::allocator<char>>
|
||||
<substitution2> ::= <sem-subistr> i # ::std::basic_istream<char, std::char_traits<char> >
|
||||
<substitution2> ::= <sem-subostr> o # ::std::basic_ostream<char, std::char_traits<char> >
|
||||
<substitution2> ::= <sem-subiostr> d # ::std::basic_iostream<char, std::char_traits<char> >
|
||||
<operator-name> ::= a <operator-name-a>
|
||||
<operator-name> ::= c <operator-name-c>
|
||||
<operator-name> ::= d <operator-name-d>
|
||||
<operator-name> ::= e <operator-name-e>
|
||||
<operator-name> ::= g <operator-name-g>
|
||||
<operator-name> ::= i <operator-name-i>
|
||||
<operator-name> ::= l <operator-name-l>
|
||||
<operator-name> ::= m <operator-name-m>
|
||||
<operator-name> ::= n <operator-name-n>
|
||||
<operator-name> ::= o <operator-name-o>
|
||||
<operator-name> ::= p <operator-name-p>
|
||||
<operator-name> ::= q <operator-name-q>
|
||||
<operator-name> ::= r <operator-name-r>
|
||||
<operator-name> ::= s <operator-name-s>
|
||||
<operator-name-a> ::= <sem-setopaa> a # &&
|
||||
<operator-name-a> ::= <sem-setopad> d # & (unary)
|
||||
<operator-name-a> ::= <sem-setopan> n # &
|
||||
<operator-name-a> ::= <sem-setopat> t # alignof (a type)
|
||||
<operator-name-a> ::= <sem-setopaz> z # alignof (an expression)
|
||||
<operator-name-a> ::= <sem-setopass> S # =
|
||||
<operator-name-a> ::= <sem-setopann> N # &=
|
||||
<operator-name-c> ::= <sem-setopcm> m # ,
|
||||
<operator-name-c> ::= <sem-setopcl> l # ()
|
||||
<operator-name-c> ::= <sem-setopco> o # ~
|
||||
<operator-name-cv> ::= <sem-setopcv> v <type> <sem-par2spec> # (cast)
|
||||
<operator-name-d> ::= <sem-setopdl> l # delete
|
||||
<operator-name-d> ::= <sem-setopda> a # delete[]
|
||||
<operator-name-d> ::= <sem-setopde> e # * (unary)
|
||||
<operator-name-d> ::= <sem-setopdv> v # /
|
||||
<operator-name-d> ::= <sem-setopdvv> V # /=
|
||||
<operator-name-e> ::= <sem-setopeo> o # ^
|
||||
<operator-name-e> ::= <sem-setopeoo> O # ^=
|
||||
<operator-name-e> ::= <sem-setopeq> q # ==
|
||||
<operator-name-g> ::= <sem-setopgt> t # >
|
||||
<operator-name-g> ::= <sem-setopge> e # >=
|
||||
<operator-name-i> ::= <sem-setopix> x # []
|
||||
<operator-name-l> ::= <sem-setopls> s # <<
|
||||
<operator-name-l> ::= <sem-setoplss> S # <<=
|
||||
<operator-name-l> ::= <sem-setoplt> t # <
|
||||
<operator-name-l> ::= <sem-setople> e # <=
|
||||
<operator-name-m> ::= <sem-setopmi> i # -
|
||||
<operator-name-m> ::= <sem-setopml> l # *
|
||||
<operator-name-m> ::= <sem-setopmii> I # -=
|
||||
<operator-name-m> ::= <sem-setopmll> L # *=
|
||||
<operator-name-m> ::= <sem-setopmm> m # -- (postfix in <expression> context)
|
||||
<operator-name-n> ::= <sem-setopnw> w # new
|
||||
<operator-name-n> ::= <sem-setopna> a # new[]
|
||||
<operator-name-n> ::= <sem-setopng> g # - (unary)
|
||||
<operator-name-n> ::= <sem-setopne> e # !=
|
||||
<operator-name-n> ::= <sem-setopnt> t # !
|
||||
<operator-name-o> ::= <sem-setopor> r # |
|
||||
<operator-name-o> ::= <sem-setoporr> R # |=
|
||||
<operator-name-o> ::= <sem-setopoo> o # ||
|
||||
<operator-name-p> ::= <sem-setopps> s # + (unary)
|
||||
<operator-name-p> ::= <sem-setoppl> l # +
|
||||
<operator-name-p> ::= <sem-setoppll> L # +=
|
||||
<operator-name-p> ::= <sem-setoppp> p # ++ (postfix in <expression> context)
|
||||
<operator-name-p> ::= <sem-setoppm> m # ->*
|
||||
<operator-name-p> ::= <sem-setoppt> t # ->
|
||||
<operator-name-q> ::= <sem-setopqu> u # ?
|
||||
<operator-name-r> ::= <sem-setoprm> m # %
|
||||
<operator-name-r> ::= <sem-setoprmm> M # %=
|
||||
<operator-name-r> ::= <sem-setoprs> s # >>
|
||||
<operator-name-r> ::= <sem-setoprss> S # >>=
|
||||
<operator-name-s> ::= <sem-setopst> t # sizeof (a type)
|
||||
<operator-name-s> ::= <sem-setopsz> z # sizeof (an expression)
|
||||
<expr-primary> ::= <sem-beginexpr> L <builtin-type> <sem-type2expr> <expr-number> E <sem-storeexpr>
|
||||
<expr-number> ::= <sem-exprval> <number>
|
||||
<sem-addchartoname> ::=
|
||||
<sem-storename> ::=
|
||||
<sem-loadid> ::=
|
||||
<sem-loadarr> ::=
|
||||
<sem-ssno> ::=
|
||||
<sem-ssnest> ::=
|
||||
<sem-stunq> ::=
|
||||
<sem-loadtsub> ::=
|
||||
<sem-type2expr> ::=
|
||||
<sem-exprval> ::=
|
||||
<sem-beginexpr> ::=
|
||||
<sem-storeexpr> ::=
|
||||
<sem-copyexpr> ::=
|
||||
<sem-storepar> ::=
|
||||
<sem-begintempl> ::=
|
||||
<sem-skiptempl> ::=
|
||||
<sem-storetemparg> ::=
|
||||
<sem-storetemplate> ::=
|
||||
<sem-setnametf> ::=
|
||||
<sem-par2f> ::=
|
||||
<sem-unq2f> ::=
|
||||
<sem-unq2p> ::=
|
||||
<sem-setnamex> ::=
|
||||
<sem-setnameo> ::=
|
||||
<sem-par2spec> ::=
|
||||
<sem-par2ret> ::=
|
||||
<sem-settypev> ::=
|
||||
<sem-settypew> ::=
|
||||
<sem-settypeb> ::=
|
||||
<sem-settypec> ::=
|
||||
<sem-settypea> ::=
|
||||
<sem-settypeh> ::=
|
||||
<sem-settypes> ::=
|
||||
<sem-settypet> ::=
|
||||
<sem-settypei> ::=
|
||||
<sem-settypej> ::=
|
||||
<sem-settypel> ::=
|
||||
<sem-settypem> ::=
|
||||
<sem-settypex> ::=
|
||||
<sem-settypey> ::=
|
||||
<sem-settypen> ::=
|
||||
<sem-settypeo> ::=
|
||||
<sem-settypef> ::=
|
||||
<sem-settyped> ::=
|
||||
<sem-settypee> ::=
|
||||
<sem-settypeg> ::=
|
||||
<sem-settypez> ::=
|
||||
<sem-setrestrict> ::=
|
||||
<sem-setvolatile> ::=
|
||||
<sem-setconst> ::=
|
||||
<sem-setptr> ::=
|
||||
<sem-setref> ::=
|
||||
<sem-setrval> ::=
|
||||
<sem-setcpair> ::=
|
||||
<sem-setim> ::=
|
||||
<sem-substd> ::=
|
||||
<sem-subalc> ::=
|
||||
<sem-substr> ::=
|
||||
<sem-substrs> ::=
|
||||
<sem-subistr> ::=
|
||||
<sem-subostr> ::=
|
||||
<sem-subiostr> ::=
|
||||
<sem-loadsub> ::=
|
||||
<sem-setnamec> ::=
|
||||
<sem-setnamed> ::=
|
||||
<sem-setopnw> ::=
|
||||
<sem-setopna> ::=
|
||||
<sem-setopdl> ::=
|
||||
<sem-setopda> ::=
|
||||
<sem-setopps> ::=
|
||||
<sem-setopng> ::=
|
||||
<sem-setopad> ::=
|
||||
<sem-setopde> ::=
|
||||
<sem-setopco> ::=
|
||||
<sem-setoppl> ::=
|
||||
<sem-setopmi> ::=
|
||||
<sem-setopml> ::=
|
||||
<sem-setopdv> ::=
|
||||
<sem-setoprm> ::=
|
||||
<sem-setopan> ::=
|
||||
<sem-setopor> ::=
|
||||
<sem-setopeo> ::=
|
||||
<sem-setopass> ::=
|
||||
<sem-setoppll> ::=
|
||||
<sem-setopmii> ::=
|
||||
<sem-setopmll> ::=
|
||||
<sem-setopdvv> ::=
|
||||
<sem-setoprmm> ::=
|
||||
<sem-setopann> ::=
|
||||
<sem-setoporr> ::=
|
||||
<sem-setopeoo> ::=
|
||||
<sem-setopls> ::=
|
||||
<sem-setoprs> ::=
|
||||
<sem-setoplss> ::=
|
||||
<sem-setoprss> ::=
|
||||
<sem-setopeq> ::=
|
||||
<sem-setopne> ::=
|
||||
<sem-setoplt> ::=
|
||||
<sem-setopgt> ::=
|
||||
<sem-setople> ::=
|
||||
<sem-setopnt> ::=
|
||||
<sem-setopaa> ::=
|
||||
<sem-setopoo> ::=
|
||||
<sem-setoppp> ::=
|
||||
<sem-setopmm> ::=
|
||||
<sem-setopcm> ::=
|
||||
<sem-setoppm> ::=
|
||||
<sem-setoppt> ::=
|
||||
<sem-setopcl> ::=
|
||||
<sem-setopix> ::=
|
||||
<sem-setopge> ::=
|
||||
<sem-setopqu> ::=
|
||||
<sem-setopst> ::=
|
||||
<sem-setopsz> ::=
|
||||
<sem-setopat> ::=
|
||||
<sem-setopaz> ::=
|
||||
<sem-setopcv> ::=
|
||||
<sem-setopxx> ::=
|
||||
<sem-setnamef> ::=
|
||||
<sem-setnamevt> ::=
|
||||
<sem-reversename> ::=
|
||||
<sem-setprivate> ::=
|
||||
<sem-setpublic> ::=
|
||||
<sem-setprotected> ::=
|
||||
<sem-setfcdecl> ::=
|
||||
<sem-setfpascal> ::=
|
||||
<sem-setffortran> ::=
|
||||
<sem-setfthiscall> ::=
|
||||
<sem-setfstdcall> ::=
|
||||
<sem-setffastcall> ::=
|
||||
<sem-setfinterrupt> ::=
|
||||
<sem-setunion> ::=
|
||||
<sem-setstruct> ::=
|
||||
<sem-setclass> ::=
|
||||
<sem-setenum> ::=
|
||||
<sem-setstatic> ::=
|
||||
<sem-setvirtual> ::=
|
||||
<sem-stclconst> ::=
|
||||
<sem-stclvol> ::=
|
||||
<sem-stclfar> ::=
|
||||
<sem-stclhuge> ::=
|
||||
<sem-savenamesub> ::=
|
||||
<sem-loadnamesub> ::=
|
||||
<sem-mstemplsub> ::=
|
||||
<sem-setnamer0> ::=
|
||||
<sem-setnamer1> ::=
|
||||
<sem-setnamer2> ::=
|
||||
<sem-setnamer3> ::=
|
||||
<sem-setnamer4> ::=
|
||||
<sem-setname_a> ::=
|
||||
<sem-setname_b> ::=
|
||||
<sem-setname_c> ::=
|
||||
<sem-setname_d> ::=
|
||||
<sem-setname_e> ::=
|
||||
<sem-setname_f> ::=
|
||||
<sem-setname_g> ::=
|
||||
<sem-setname_h> ::=
|
||||
<sem-setname_i> ::=
|
||||
<sem-setname_j> ::=
|
||||
<sem-setname_k> ::=
|
||||
<sem-setname_l> ::=
|
||||
<sem-setname_m> ::=
|
||||
<sem-setname_n> ::=
|
||||
<sem-setname_o> ::=
|
||||
<sem-setname_p> ::=
|
||||
<sem-setname_q> ::=
|
||||
<sem-setname_r> ::=
|
||||
<sem-setname_s> ::=
|
||||
<sem-setname_t> ::=
|
||||
<sem-setname_u> ::=
|
||||
<sem-setname_v> ::=
|
||||
<sem-setname_w> ::=
|
||||
<sem-setname_x> ::=
|
||||
<sem-setname_y> ::=
|
||||
<sem-setname_z> ::=
|
||||
<sem-templ2tftpl> ::=
|
||||
<sem-beginbsub> ::= #begin built-in substitution
|
||||
<sem-loadbsub> ::=
|
||||
<sem-addmconst> ::=
|
||||
<sem-addmvol> ::=
|
||||
<sem-addmfar> ::=
|
||||
<sem-addmhuge> ::=
|
||||
<sem-loadmsnum> ::=
|
||||
<sem-numtorttibcd> ::=
|
||||
<sem-numtotype> ::=
|
||||
<sem-normalizeparname> ::=
|
||||
<sem-borlandid> ::=
|
||||
<sem-loadborlandsub> ::=
|
||||
<sem-borlandarr> ::=
|
||||
<sem-end> ::=
|
|
@ -1,534 +0,0 @@
|
|||
<mangled-name> ::= ? <mangled-name-2>
|
||||
<mangled-name-2> ::= ? <mangled-name-qs>
|
||||
<mangled-name-qs> ::= _ <mangled-name-qssub>
|
||||
<mangled-name-qs> ::= 0 <name-cover> <sem-setnamec> <sem-unq2f> <modif> <const-vol> <calling-conv> @ <parameters> <terma> Z <sem-end>
|
||||
<mangled-name-qs> ::= 1 <name-cover> <sem-setnamed> <sem-unq2f> <modif> <const-vol> <calling-conv> @ <parameters> <terma>Z <sem-end>
|
||||
<mangled-name-qs> ::= <sem-setnameo> <optype> <name-cover> <sem-unq2f> <mangled-name-data>
|
||||
<optype> ::= <sem-setopdl> 3
|
||||
<optype> ::= <sem-setopix> A
|
||||
<optype> ::= <sem-setopcl> R
|
||||
<optype> ::= <sem-setoppt> C
|
||||
<optype> ::= <sem-setoppp> E
|
||||
<optype> ::= <sem-setopmm> F
|
||||
<optype> ::= <sem-setopnw> 2
|
||||
<optype> ::= <sem-setopde> D
|
||||
<optype> ::= <sem-setopad> I
|
||||
<optype> ::= <sem-setopps> H
|
||||
<optype> ::= <sem-setopng> G
|
||||
<optype> ::= <sem-setopnt> 7
|
||||
<optype> ::= <sem-setopco> S
|
||||
<optype> ::= <sem-setoppm> J
|
||||
<optype> ::= <sem-setopdv> K
|
||||
<optype> ::= <sem-setoprm> L
|
||||
<optype> ::= <sem-setopls> 6
|
||||
<optype> ::= <sem-setoprs> 5
|
||||
<optype> ::= <sem-setoplt> M
|
||||
<optype> ::= <sem-setopgt> O
|
||||
<optype> ::= <sem-setople> N
|
||||
<optype> ::= <sem-setopge> P
|
||||
<optype> ::= <sem-setopeq> 8
|
||||
<optype> ::= <sem-setopne> 9
|
||||
<optype> ::= <sem-setopor> U
|
||||
<optype> ::= <sem-setopeo> T
|
||||
<optype> ::= <sem-setopaa> V
|
||||
<optype> ::= <sem-setopoo> W
|
||||
<optype> ::= <sem-setopass> 4
|
||||
<optype> ::= <sem-setopmll> X
|
||||
<optype> ::= <sem-setoppll> Y
|
||||
<optype> ::= <sem-setopmii> Z
|
||||
<optype> ::= <sem-setopcm> Q
|
||||
<optype> ::= <sem-setopcv> B
|
||||
<optype_> ::= <sem-setopna> U
|
||||
<optype_> ::= <sem-setopda> V
|
||||
<optype_> ::= <sem-setopdvv> 0
|
||||
<optype_> ::= <sem-setoprmm> 1
|
||||
<optype_> ::= <sem-setoprss> 2
|
||||
<optype_> ::= <sem-setoplss> 3
|
||||
<optype_> ::= <sem-setopann> 4
|
||||
<optype_> ::= <sem-setoporr> 5
|
||||
<optype_> ::= <sem-setopeoo> 6
|
||||
<terma> ::=
|
||||
<terma> ::= @
|
||||
<mangled-name-qssub> ::= 7 <name-cover> <sem-setnamevt> <sem-unq2f> <mangled-name-data>
|
||||
<mangled-name-qssub> ::= R <mangled-name-qssub-r>
|
||||
<mangled-name-qssub-r> ::= <r-num> <name-cover> <sem-unq2f> 8 <sem-end>
|
||||
<mangled-name-qssub-r> ::= <sem-setnamer4> 4 <name-cover> <sem-unq2f> <mangled-name-data>
|
||||
<mangled-name-qssub-r> ::= <sem-setnamer1> 1 <sem-loadmsnum> <msnum> <sem-numtorttibcd> <sem-loadmsnum> <msnum> <sem-numtorttibcd> <sem-loadmsnum> <msnum> <sem-numtorttibcd> <sem-loadmsnum> <msnum> <sem-numtorttibcd> <name-cover> <sem-unq2f> <terma> 8 <sem-end>
|
||||
<mangled-name-qssub-r> ::= <sem-setnamer0> 0 <storage-return> <type> <sem-par2ret> @ 8 <sem-end>
|
||||
<r-num> ::= <sem-setnamer2> 2
|
||||
<r-num> ::= <sem-setnamer3> 3
|
||||
<mangled-name-qssub> ::= <sem-setnameo> <optype_> <name-cover> <sem-unq2f> <mangled-name-data>
|
||||
<mangled-name-qssub> ::= <qssub> <name-cover> <sem-unq2f> <mangled-name-data>
|
||||
<qssub> ::= <sem-setname_a> A
|
||||
<qssub> ::= <sem-setname_b> B
|
||||
<qssub> ::= <sem-setname_d> D
|
||||
<qssub> ::= <sem-setname_e> E
|
||||
<qssub> ::= <sem-setname_f> F
|
||||
<qssub> ::= <sem-setname_g> G
|
||||
<qssub> ::= <sem-setname_h> H
|
||||
<qssub> ::= <sem-setname_i> I
|
||||
<qssub> ::= <sem-setname_j> J
|
||||
<qssub> ::= <sem-setname_k> K
|
||||
<qssub> ::= <sem-setname_l> L
|
||||
<qssub> ::= <sem-setname_m> M
|
||||
<qssub> ::= <sem-setname_n> N
|
||||
<qssub> ::= <sem-setname_o> O
|
||||
<qssub> ::= <sem-setname_q> Q
|
||||
<qssub> ::= <sem-setname_s> S
|
||||
<qssub> ::= <sem-setname_t> T
|
||||
<qssub> ::= <sem-setname_x> X
|
||||
<qssub> ::= <sem-setname_y> Y
|
||||
<storage-return> ::=
|
||||
<storage-return> ::= ? <storage-return-2>
|
||||
<storage-return-2> ::= A
|
||||
<storage-return-2> ::= <sem-setconst> B
|
||||
<storage-return-2> ::= <sem-setvol> C
|
||||
<storage-return-2> ::= <sem-setconst> <sem-setvol> D
|
||||
<mangled-name-qs> ::= <name-cover-qs> <sem-unq2f> <mangled-name-data>
|
||||
<mangled-name-2> ::= <name-cover-noqs> <sem-unq2f> <mangled-name-data>
|
||||
<mangled-name-data> ::= <data-object> <sem-end>
|
||||
<mangled-name-data> ::= <modif> <const-vol> <calling-conv> <storage-return> <type> <sem-par2ret> <parameters> <terma> Z <sem-end>
|
||||
<mangled-name-data> ::= <near-far> <calling-conv> <storage-return> <type> <sem-par2ret> <parameters> <terma> Z <sem-end>
|
||||
<data-object> ::= 6 <storage-class> <terma>
|
||||
<data-object> ::= 3 <sem-setnamex> <type> <sem-par2ret> <storage-class> #global object
|
||||
<data-object> ::= 2 <sem-setnamex> <sem-setpublic> <sem-setstatic> <type> <sem-par2ret> <storage-class> #static class member object
|
||||
<data-object> ::= 1 <sem-setnamex> <sem-setprotected> <sem-setstatic> <type> <sem-par2ret> <storage-class> #static class member object
|
||||
<data-object> ::= 0 <sem-setnamex> <sem-setprivate> <sem-setstatic> <type> <sem-par2ret> <storage-class> #static class member object
|
||||
<msnum> ::= ?
|
||||
<msnum> ::= 0
|
||||
<msnum> ::= 1
|
||||
<msnum> ::= 2
|
||||
<msnum> ::= 3
|
||||
<msnum> ::= 4
|
||||
<msnum> ::= 5
|
||||
<msnum> ::= 6
|
||||
<msnum> ::= 7
|
||||
<msnum> ::= 8
|
||||
<msnum> ::= 9
|
||||
<msnum> ::= A
|
||||
<msnum> ::= B
|
||||
<msnum> ::= C
|
||||
<msnum> ::= D
|
||||
<msnum> ::= E
|
||||
<msnum> ::= F
|
||||
<msnum> ::= G
|
||||
<msnum> ::= H
|
||||
<msnum> ::= I
|
||||
<msnum> ::= J
|
||||
<msnum> ::= K
|
||||
<msnum> ::= L
|
||||
<msnum> ::= M
|
||||
<msnum> ::= N
|
||||
<msnum> ::= O
|
||||
<msnum> ::= P
|
||||
<storage-class> ::= Q1@ #member pointers, member function pointers
|
||||
<storage-class> ::= A #near
|
||||
<storage-class> ::= <sem-stclconst> B #const
|
||||
<storage-class> ::= <sem-stclvol> C #volatile
|
||||
<storage-class> ::= <sem-stclconst> <sem-stclvol> D #const volatile
|
||||
<storage-class> ::= <sem-stclfar> E #far
|
||||
<storage-class> ::= <sem-stclconst> <sem-stclfar> F #const far
|
||||
<storage-class> ::= <sem-stclvol> <sem-stclfar> G #volatile far
|
||||
<storage-class> ::= <sem-stclconst> <sem-stclvol> <sem-stclfar> H #const volatile far
|
||||
<storage-class> ::= <sem-stclhuge> I #huge
|
||||
<modif> ::= <sem-setprivate> A #private default
|
||||
<modif> ::= <sem-setprivate> B #private far
|
||||
<modif> ::= <sem-setprivate> <sem-setstatic> C #private static
|
||||
<modif> ::= <sem-setprivate> <sem-setstatic> D #private static far
|
||||
<modif> ::= <sem-setprivate> <sem-setvirtual> E #private virtual
|
||||
<modif> ::= <sem-setprivate> <sem-setvirtual> F #private virtual far
|
||||
<modif> ::= <sem-setprotected> I #protected default
|
||||
<modif> ::= <sem-setprotected> J #protected far
|
||||
<modif> ::= <sem-setprotected> <sem-setstatic> K #protected static
|
||||
<modif> ::= <sem-setprotected> <sem-setstatic> L #protected static far
|
||||
<modif> ::= <sem-setprotected> <sem-setvirtual> M #protected virtual
|
||||
<modif> ::= <sem-setprotected> <sem-setvirtual> N #protected virtual far
|
||||
<modif> ::= <sem-setpublic> Q #public default
|
||||
<modif> ::= <sem-setpublic> R #public far
|
||||
<modif> ::= <sem-setpublic> <sem-setstatic> S #public static
|
||||
<modif> ::= <sem-setpublic> <sem-setstatic> T #public static far
|
||||
<modif> ::= <sem-setpublic> <sem-setvirtual> U #public virtual
|
||||
<modif> ::= <sem-setpublic> <sem-setvirtual> V #public virtual far
|
||||
<const-vol-e> ::=
|
||||
<const-vol-e> ::= <const-vol>
|
||||
<const-vol> ::= A #default
|
||||
<const-vol> ::= <sem-addmconst> B #const
|
||||
<const-vol> ::= <sem-addmvol> C #volatile
|
||||
<const-vol> ::= <sem-addmconst> <sem-addmvol> D #const volatile
|
||||
<calling-conv> ::= <sem-setfcdecl> A #__cdecl
|
||||
<calling-conv> ::= <sem-setfpascal> C #__pascal
|
||||
<calling-conv> ::= <sem-setfthiscall> E #__thiscall
|
||||
<calling-conv> ::= <sem-setfstdcall> G #__stdcall
|
||||
<calling-conv> ::= <sem-setffastcall> I #__fastcall
|
||||
<name-cover-qs> ::= <name-qs> @ <namespace-x> @
|
||||
<name-cover-noqs> ::= <name-element-noqs> <namespace-x> @
|
||||
<name-cover> ::= <name-element> <namespace-x> @
|
||||
<name-cover> ::= @
|
||||
<name-element> ::= <name> @
|
||||
<name-element> ::= <name-sub>
|
||||
<name-element-noqs> ::= <name-noqs> @
|
||||
<name-element-noqs> ::= <name-sub>
|
||||
<name-sub> ::= <sem-loadnamesub> 0
|
||||
<name-sub> ::= <sem-loadnamesub> 1
|
||||
<name-sub> ::= <sem-loadnamesub> 2
|
||||
<name-sub> ::= <sem-loadnamesub> 3
|
||||
<name-sub> ::= <sem-loadnamesub> 4
|
||||
<name-sub> ::= <sem-loadnamesub> 5
|
||||
<name-sub> ::= <sem-loadnamesub> 6
|
||||
<name-sub> ::= <sem-loadnamesub> 7
|
||||
<name-sub> ::= <sem-loadnamesub> 8
|
||||
<name-sub> ::= <sem-loadnamesub> 9
|
||||
<name-elemental> ::= <name-char-first> <name-char-more>
|
||||
<template-header> ::= <name-elemental> @
|
||||
<template-header> ::= ? <template-op>
|
||||
<template-op> ::= <sem-setnameo> <optype>
|
||||
<template-op> ::= <sem-setnameo> _ <optype_>
|
||||
<name-qs> ::= $ <template-header> <sem-begintempl> <sem-mstemplsub> <template-arg> <template-arg-more> <sem-savenamesub>
|
||||
<name-noqs> ::= <name-elemental> <sem-savenamesub>
|
||||
<name> ::= ? <name-qs>
|
||||
<name> ::= <name-noqs>
|
||||
<name-char-more> ::= <name-char> <name-char-more>
|
||||
<name-char-more> ::= <name-char-first> <name-char-more>
|
||||
<name-char-more> ::= <sem-storename>
|
||||
<namespace-x> ::= <sem-reversename>
|
||||
<namespace-x> ::= <name-element> <namespace-x>
|
||||
<template-arg-more> ::= <sem-storetemplate>
|
||||
<template-arg-more> ::= <sem-storetemparg> <template-arg> <template-arg-more>
|
||||
<template-arg> ::= <type>
|
||||
<parameters> ::= <parameter> <parameter-more>
|
||||
<parameter> ::= <type>
|
||||
<parameter-more> ::= <sem-storepar> <parameter> <parameter-more>
|
||||
<parameter-more> ::= <sem-par2f>
|
||||
<near-far> ::= Y #near
|
||||
<near-far> ::= Z #far
|
||||
<name-char-first> ::= <sem-addchartoname> _
|
||||
<name-char-first> ::= <sem-addchartoname> a
|
||||
<name-char-first> ::= <sem-addchartoname> b
|
||||
<name-char-first> ::= <sem-addchartoname> c
|
||||
<name-char-first> ::= <sem-addchartoname> d
|
||||
<name-char-first> ::= <sem-addchartoname> e
|
||||
<name-char-first> ::= <sem-addchartoname> f
|
||||
<name-char-first> ::= <sem-addchartoname> g
|
||||
<name-char-first> ::= <sem-addchartoname> h
|
||||
<name-char-first> ::= <sem-addchartoname> i
|
||||
<name-char-first> ::= <sem-addchartoname> j
|
||||
<name-char-first> ::= <sem-addchartoname> k
|
||||
<name-char-first> ::= <sem-addchartoname> l
|
||||
<name-char-first> ::= <sem-addchartoname> m
|
||||
<name-char-first> ::= <sem-addchartoname> n
|
||||
<name-char-first> ::= <sem-addchartoname> o
|
||||
<name-char-first> ::= <sem-addchartoname> p
|
||||
<name-char-first> ::= <sem-addchartoname> q
|
||||
<name-char-first> ::= <sem-addchartoname> r
|
||||
<name-char-first> ::= <sem-addchartoname> s
|
||||
<name-char-first> ::= <sem-addchartoname> t
|
||||
<name-char-first> ::= <sem-addchartoname> u
|
||||
<name-char-first> ::= <sem-addchartoname> v
|
||||
<name-char-first> ::= <sem-addchartoname> w
|
||||
<name-char-first> ::= <sem-addchartoname> x
|
||||
<name-char-first> ::= <sem-addchartoname> y
|
||||
<name-char-first> ::= <sem-addchartoname> z
|
||||
<name-char-first> ::= <sem-addchartoname> A
|
||||
<name-char-first> ::= <sem-addchartoname> B
|
||||
<name-char-first> ::= <sem-addchartoname> C
|
||||
<name-char-first> ::= <sem-addchartoname> D
|
||||
<name-char-first> ::= <sem-addchartoname> E
|
||||
<name-char-first> ::= <sem-addchartoname> F
|
||||
<name-char-first> ::= <sem-addchartoname> G
|
||||
<name-char-first> ::= <sem-addchartoname> H
|
||||
<name-char-first> ::= <sem-addchartoname> I
|
||||
<name-char-first> ::= <sem-addchartoname> J
|
||||
<name-char-first> ::= <sem-addchartoname> K
|
||||
<name-char-first> ::= <sem-addchartoname> L
|
||||
<name-char-first> ::= <sem-addchartoname> M
|
||||
<name-char-first> ::= <sem-addchartoname> N
|
||||
<name-char-first> ::= <sem-addchartoname> O
|
||||
<name-char-first> ::= <sem-addchartoname> P
|
||||
<name-char-first> ::= <sem-addchartoname> Q
|
||||
<name-char-first> ::= <sem-addchartoname> R
|
||||
<name-char-first> ::= <sem-addchartoname> S
|
||||
<name-char-first> ::= <sem-addchartoname> T
|
||||
<name-char-first> ::= <sem-addchartoname> U
|
||||
<name-char-first> ::= <sem-addchartoname> V
|
||||
<name-char-first> ::= <sem-addchartoname> W
|
||||
<name-char-first> ::= <sem-addchartoname> X
|
||||
<name-char-first> ::= <sem-addchartoname> Y
|
||||
<name-char-first> ::= <sem-addchartoname> Z
|
||||
<name-char> ::= <sem-addchartoname> 0
|
||||
<name-char> ::= <sem-addchartoname> 1
|
||||
<name-char> ::= <sem-addchartoname> 2
|
||||
<name-char> ::= <sem-addchartoname> 3
|
||||
<name-char> ::= <sem-addchartoname> 4
|
||||
<name-char> ::= <sem-addchartoname> 5
|
||||
<name-char> ::= <sem-addchartoname> 6
|
||||
<name-char> ::= <sem-addchartoname> 7
|
||||
<name-char> ::= <sem-addchartoname> 8
|
||||
<name-char> ::= <sem-addchartoname> 9
|
||||
<name-char> ::= <sem-addchartoname> $
|
||||
<type> ::= <typesub>
|
||||
<type> ::= _ <sem-beginbsub> <type_>
|
||||
<type> ::= $ <type-ds>
|
||||
<type-ds> ::= $ <type-dsds>
|
||||
<type-ds> ::= 0 <sem-loadmsnum> <msnum> <sem-numtotype>
|
||||
<type-dsds> ::= C <dsds-modifier> <type>
|
||||
<dsds-modifier> ::= A
|
||||
<dsds-modifier> ::= <sem-setconst> B
|
||||
<dsds-modifier> ::= <sem-setvolatile> C
|
||||
<dsds-modifier> ::= <sem-setvolatile> <sem-setconst> D
|
||||
<dsds-modifier> ::= E
|
||||
<dsds-modifier> ::= F
|
||||
<dsds-modifier> ::= <sem-setvolatile> G
|
||||
<dsds-modifier> ::= <sem-setvolatile> <sem-setconst> H
|
||||
<dsds-modifier> ::= I
|
||||
<dsds-modifier> ::= <sem-setconst> J
|
||||
<dsds-modifier> ::= <sem-setvolatile> K
|
||||
<dsds-modifier> ::= <sem-setvolatile> <sem-setconst> L
|
||||
<typesub> ::= <sem-loadbsub> 0
|
||||
<typesub> ::= <sem-loadbsub> 1
|
||||
<typesub> ::= <sem-loadbsub> 2
|
||||
<typesub> ::= <sem-loadbsub> 3
|
||||
<typesub> ::= <sem-loadbsub> 4
|
||||
<typesub> ::= <sem-loadbsub> 5
|
||||
<typesub> ::= <sem-loadbsub> 6
|
||||
<typesub> ::= <sem-loadbsub> 7
|
||||
<typesub> ::= <sem-loadbsub> 8
|
||||
<typesub> ::= <sem-loadbsub> 9
|
||||
<type> ::= <sem-settypev> X #void
|
||||
<type> ::= <sem-settypec> D #char
|
||||
<type> ::= <sem-settypea> C #signed char
|
||||
<type> ::= <sem-settypeh> E #unsigned char
|
||||
<type> ::= <sem-settypes> F #short int
|
||||
<type> ::= <sem-settypet> G #unsigned short int
|
||||
<type> ::= <sem-settypei> H #int
|
||||
<type> ::= <sem-settypej> I #unsigned int
|
||||
<type> ::= <sem-settypel> J #long int
|
||||
<type> ::= <sem-settypem> K #unsigned long int
|
||||
<type> ::= <sem-settypef> M #float
|
||||
<type> ::= <sem-settyped> N #double
|
||||
<type> ::= <sem-settypee> O #long double (64-bit precision)
|
||||
<type> ::= T <sem-beginbsub> <type-t>
|
||||
<type> ::= U <sem-beginbsub> <type-u>
|
||||
<type> ::= V <sem-beginbsub> <sem-setclass> <name-cover> <sem-unq2p> #class
|
||||
<type> ::= W <sem-beginbsub> <type-w>
|
||||
<type-t> ::= <sem-setunion> <name-cover> <sem-unq2p> #union
|
||||
<type-u> ::= <sem-setstruct> <name-cover> <sem-unq2p> #struct
|
||||
<type-w> ::= 4 <sem-setenum> <name-cover> <sem-unq2p> #enum
|
||||
<type> ::= P <e> <sem-beginbsub> <type-pe> <type>
|
||||
<type> ::= Q <e> <sem-beginbsub> <type-qe> <type>
|
||||
<type> ::= R <e> <sem-beginbsub> <type-re> <type>
|
||||
<type> ::= S <e> <sem-beginbsub> <type-se> <type>
|
||||
<type> ::= A <e> <sem-beginbsub> <type-ae> <type>
|
||||
<type-pe> ::= <sem-setptr> A #X *
|
||||
<type-pe> ::= <sem-setptr> <sem-setconst> B #const X *
|
||||
<type-pe> ::= <sem-setptr> <sem-setvolatile> C #volatile X *
|
||||
<type-pe> ::= <sem-setptr> <sem-setvolatile> <sem-setconst> D #const volatile X *
|
||||
<type-qe> ::= <sem-setptr> A #X * const
|
||||
<type-qe> ::= <sem-setptr> <sem-setconst> B #const X * const
|
||||
<type-qe> ::= <sem-setptr> <sem-setvolatile> C #volatile X *
|
||||
<type-qe> ::= <sem-setptr> <sem-setvolatile> <sem-setconst> D #const volatile X *
|
||||
<type-re> ::= A #X * volatile
|
||||
<type-se> ::= A #X * const volatile
|
||||
<type-pe> ::= IA #X * __restrict
|
||||
<type-ae> ::= <sem-setref> A #X &
|
||||
<type-ae> ::= <sem-setref> <sem-setconst> B #const X &
|
||||
<type-ae> ::= <sem-setref> <sem-setvolatile> C #volatile X &
|
||||
<type-ae> ::= <sem-setref> <sem-setvolatile> <sem-setconst> D #const volatile X &
|
||||
<type-pa> ::= #X[] (as global object)
|
||||
<type_> ::= <sem-settypeb> N #bool
|
||||
<type_> ::= <sem-settypex> J #long long (__int64)
|
||||
<type_> ::= <sem-settypey> K #unsigned long long (unsigned __int64)
|
||||
<type_> ::= <sem-settypew> W #wchar_t
|
||||
<type_> ::= T #long double (80-bit precision Intel compiler)
|
||||
<type_> ::= Z #long double (80-bit precision Symantec/Digital Mars compiler)
|
||||
<e> ::= E
|
||||
<e> ::=
|
||||
<sem-addchartoname> ::=
|
||||
<sem-storename> ::=
|
||||
<sem-loadid> ::=
|
||||
<sem-loadarr> ::=
|
||||
<sem-ssno> ::=
|
||||
<sem-ssnest> ::=
|
||||
<sem-stunq> ::=
|
||||
<sem-loadtsub> ::=
|
||||
<sem-type2expr> ::=
|
||||
<sem-exprval> ::=
|
||||
<sem-beginexpr> ::=
|
||||
<sem-storeexpr> ::=
|
||||
<sem-copyexpr> ::=
|
||||
<sem-storepar> ::=
|
||||
<sem-begintempl> ::=
|
||||
<sem-skiptempl> ::=
|
||||
<sem-storetemparg> ::=
|
||||
<sem-storetemplate> ::=
|
||||
<sem-setnametf> ::=
|
||||
<sem-par2f> ::=
|
||||
<sem-unq2f> ::=
|
||||
<sem-unq2p> ::=
|
||||
<sem-setnamex> ::=
|
||||
<sem-setnameo> ::=
|
||||
<sem-par2spec> ::=
|
||||
<sem-par2ret> ::=
|
||||
<sem-settypev> ::=
|
||||
<sem-settypew> ::=
|
||||
<sem-settypeb> ::=
|
||||
<sem-settypec> ::=
|
||||
<sem-settypea> ::=
|
||||
<sem-settypeh> ::=
|
||||
<sem-settypes> ::=
|
||||
<sem-settypet> ::=
|
||||
<sem-settypei> ::=
|
||||
<sem-settypej> ::=
|
||||
<sem-settypel> ::=
|
||||
<sem-settypem> ::=
|
||||
<sem-settypex> ::=
|
||||
<sem-settypey> ::=
|
||||
<sem-settypen> ::=
|
||||
<sem-settypeo> ::=
|
||||
<sem-settypef> ::=
|
||||
<sem-settyped> ::=
|
||||
<sem-settypee> ::=
|
||||
<sem-settypeg> ::=
|
||||
<sem-settypez> ::=
|
||||
<sem-setrestrict> ::=
|
||||
<sem-setvolatile> ::=
|
||||
<sem-setconst> ::=
|
||||
<sem-setptr> ::=
|
||||
<sem-setref> ::=
|
||||
<sem-setrval> ::=
|
||||
<sem-setcpair> ::=
|
||||
<sem-setim> ::=
|
||||
<sem-substd> ::=
|
||||
<sem-subalc> ::=
|
||||
<sem-substr> ::=
|
||||
<sem-substrs> ::=
|
||||
<sem-subistr> ::=
|
||||
<sem-subostr> ::=
|
||||
<sem-subiostr> ::=
|
||||
<sem-loadsub> ::=
|
||||
<sem-setnamec> ::=
|
||||
<sem-setnamed> ::=
|
||||
<sem-setopnw> ::=
|
||||
<sem-setopna> ::=
|
||||
<sem-setopdl> ::=
|
||||
<sem-setopda> ::=
|
||||
<sem-setopps> ::=
|
||||
<sem-setopng> ::=
|
||||
<sem-setopad> ::=
|
||||
<sem-setopde> ::=
|
||||
<sem-setopco> ::=
|
||||
<sem-setoppl> ::=
|
||||
<sem-setopmi> ::=
|
||||
<sem-setopml> ::=
|
||||
<sem-setopdv> ::=
|
||||
<sem-setoprm> ::=
|
||||
<sem-setopan> ::=
|
||||
<sem-setopor> ::=
|
||||
<sem-setopeo> ::=
|
||||
<sem-setopass> ::=
|
||||
<sem-setoppll> ::=
|
||||
<sem-setopmii> ::=
|
||||
<sem-setopmll> ::=
|
||||
<sem-setopdvv> ::=
|
||||
<sem-setoprmm> ::=
|
||||
<sem-setopann> ::=
|
||||
<sem-setoporr> ::=
|
||||
<sem-setopeoo> ::=
|
||||
<sem-setopls> ::=
|
||||
<sem-setoprs> ::=
|
||||
<sem-setoplss> ::=
|
||||
<sem-setoprss> ::=
|
||||
<sem-setopeq> ::=
|
||||
<sem-setopne> ::=
|
||||
<sem-setoplt> ::=
|
||||
<sem-setopgt> ::=
|
||||
<sem-setople> ::=
|
||||
<sem-setopnt> ::=
|
||||
<sem-setopaa> ::=
|
||||
<sem-setopoo> ::=
|
||||
<sem-setoppp> ::=
|
||||
<sem-setopmm> ::=
|
||||
<sem-setopcm> ::=
|
||||
<sem-setoppm> ::=
|
||||
<sem-setoppt> ::=
|
||||
<sem-setopcl> ::=
|
||||
<sem-setopix> ::=
|
||||
<sem-setopge> ::=
|
||||
<sem-setopqu> ::=
|
||||
<sem-setopst> ::=
|
||||
<sem-setopsz> ::=
|
||||
<sem-setopat> ::=
|
||||
<sem-setopaz> ::=
|
||||
<sem-setopcv> ::=
|
||||
<sem-setopxx> ::=
|
||||
<sem-setnamef> ::=
|
||||
<sem-setnamevt> ::=
|
||||
<sem-reversename> ::=
|
||||
<sem-setprivate> ::=
|
||||
<sem-setpublic> ::=
|
||||
<sem-setprotected> ::=
|
||||
<sem-setfcdecl> ::=
|
||||
<sem-setfpascal> ::=
|
||||
<sem-setffortran> ::=
|
||||
<sem-setfthiscall> ::=
|
||||
<sem-setfstdcall> ::=
|
||||
<sem-setffastcall> ::=
|
||||
<sem-setfinterrupt> ::=
|
||||
<sem-setunion> ::=
|
||||
<sem-setstruct> ::=
|
||||
<sem-setclass> ::=
|
||||
<sem-setenum> ::=
|
||||
<sem-setstatic> ::=
|
||||
<sem-setvirtual> ::=
|
||||
<sem-stclconst> ::=
|
||||
<sem-stclvol> ::=
|
||||
<sem-stclfar> ::=
|
||||
<sem-stclhuge> ::=
|
||||
<sem-savenamesub> ::=
|
||||
<sem-loadnamesub> ::=
|
||||
<sem-mstemplsub> ::=
|
||||
<sem-setnamer0> ::=
|
||||
<sem-setnamer1> ::=
|
||||
<sem-setnamer2> ::=
|
||||
<sem-setnamer3> ::=
|
||||
<sem-setnamer4> ::=
|
||||
<sem-setname_a> ::=
|
||||
<sem-setname_b> ::=
|
||||
<sem-setname_c> ::=
|
||||
<sem-setname_d> ::=
|
||||
<sem-setname_e> ::=
|
||||
<sem-setname_f> ::=
|
||||
<sem-setname_g> ::=
|
||||
<sem-setname_h> ::=
|
||||
<sem-setname_i> ::=
|
||||
<sem-setname_j> ::=
|
||||
<sem-setname_k> ::=
|
||||
<sem-setname_l> ::=
|
||||
<sem-setname_m> ::=
|
||||
<sem-setname_n> ::=
|
||||
<sem-setname_o> ::=
|
||||
<sem-setname_p> ::=
|
||||
<sem-setname_q> ::=
|
||||
<sem-setname_r> ::=
|
||||
<sem-setname_s> ::=
|
||||
<sem-setname_t> ::=
|
||||
<sem-setname_u> ::=
|
||||
<sem-setname_v> ::=
|
||||
<sem-setname_w> ::=
|
||||
<sem-setname_x> ::=
|
||||
<sem-setname_y> ::=
|
||||
<sem-setname_z> ::=
|
||||
<sem-templ2tftpl> ::=
|
||||
<sem-beginbsub> ::= #begin built-in substitution
|
||||
<sem-loadbsub> ::=
|
||||
<sem-addmconst> ::=
|
||||
<sem-addmvol> ::=
|
||||
<sem-addmfar> ::=
|
||||
<sem-addmhuge> ::=
|
||||
<sem-loadmsnum> ::=
|
||||
<sem-numtorttibcd> ::=
|
||||
<sem-numtotype> ::=
|
||||
<sem-normalizeparname> ::=
|
||||
<sem-borlandid> ::=
|
||||
<sem-loadborlandsub> ::=
|
||||
<sem-borlandarr> ::=
|
||||
<sem-end> ::=
|
File diff suppressed because it is too large
Load Diff
|
@ -1,91 +0,0 @@
|
|||
/**
|
||||
* @file src/demangler/igrams.cpp
|
||||
* @brief Internal grammar list.
|
||||
* @copyright (c) 2017 Avast Software, licensed under the MIT license
|
||||
*/
|
||||
|
||||
#include <cstdlib>
|
||||
|
||||
#include "demangler/demglobal.h"
|
||||
#include "demangler/igrams.h"
|
||||
|
||||
using namespace std;
|
||||
|
||||
namespace demangler {
|
||||
|
||||
/**
|
||||
* @brief Classes containing internal grammar.
|
||||
*/
|
||||
cIgram_msll* igram_msll = nullptr; //Microsoft Visual C++
|
||||
cIgram_gccll* igram_gccll = nullptr; //GCC
|
||||
cIgram_borlandll* igram_borlandll = nullptr; //Borland
|
||||
|
||||
//[igram] add pointers to internal grammars here
|
||||
|
||||
/**
|
||||
* @brief Function which allocates an internal grammar class and sets the internal grammar structure.
|
||||
* @param gname Grammar name. The particular internal grammar is selected using this name.
|
||||
* @param gParser Pointer to a cGram to send pointers to newly allocated grammar to.
|
||||
* @return Was the initialisation successful?
|
||||
* @retval false Grammar with the specified name was not found.
|
||||
*/
|
||||
bool initIgram(string gname, cGram* gParser) {
|
||||
bool retvalue = false;
|
||||
|
||||
//Microsoft Visual C++ (msll)
|
||||
if (gname == "ms") {
|
||||
igram_msll = new cIgram_msll;
|
||||
gParser->internalGrammarStruct = igram_msll->getInternalGrammar();
|
||||
return true;
|
||||
}
|
||||
//GCC (gccll)
|
||||
else if (gname == "gcc") {
|
||||
igram_gccll = new cIgram_gccll;
|
||||
gParser->internalGrammarStruct = igram_gccll->getInternalGrammar();
|
||||
return true;
|
||||
}
|
||||
//Borland (borlandll)
|
||||
else if (gname == "borland") {
|
||||
igram_borlandll = new cIgram_borlandll;
|
||||
gParser->internalGrammarStruct = igram_borlandll->getInternalGrammar();
|
||||
return true;
|
||||
}
|
||||
|
||||
//[igram] add allocation of internal grammars here
|
||||
|
||||
return retvalue;
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief Function which deallocates all used internal grammar classes.
|
||||
* @param gParser Pointer to a cGram to clean internal grammars from.
|
||||
*/
|
||||
void deleteIgrams(cGram* gParser) {
|
||||
|
||||
//first, delete the dynamically allocated internal llst if there is any
|
||||
if (gParser->internalGrammarStruct.llst != nullptr) {
|
||||
free(gParser->internalGrammarStruct.llst);
|
||||
gParser->internalGrammarStruct.llst = nullptr;
|
||||
}
|
||||
|
||||
//dealocate all internal grammars here...
|
||||
if (igram_msll != nullptr) {
|
||||
delete igram_msll;
|
||||
igram_msll = nullptr;
|
||||
}
|
||||
|
||||
if (igram_gccll != nullptr) {
|
||||
delete igram_gccll;
|
||||
igram_gccll = nullptr;
|
||||
}
|
||||
|
||||
if (igram_borlandll != nullptr) {
|
||||
delete igram_borlandll;
|
||||
igram_borlandll = nullptr;
|
||||
}
|
||||
|
||||
//[igram] add deallocation of internal grammars here
|
||||
|
||||
}
|
||||
|
||||
} // namespace demangler
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
42
PCSX2_qt.sln
42
PCSX2_qt.sln
|
@ -47,8 +47,6 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "pcsx2-gsrunner", "pcsx2-gsr
|
|||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "zydis", "3rdparty\zydis\zydis.vcxproj", "{67D0160C-0FE4-44B9-AC2E-82BBCF4104DF}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "demangler", "3rdparty\demangler\demangler.vcxproj", "{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "freesurround", "3rdparty\freesurround\freesurround.vcxproj", "{1DD0B31F-37F0-4A36-A521-74133ACA4737}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "vixl", "3rdparty\vixl\vixl.vcxproj", "{8906836E-F06E-46E8-B11A-74E5E8C7B8FB}"
|
||||
|
@ -882,45 +880,6 @@ Global
|
|||
{67D0160C-0FE4-44B9-AC2E-82BBCF4104DF}.Release|ARM64.ActiveCfg = Release Clang|ARM64
|
||||
{67D0160C-0FE4-44B9-AC2E-82BBCF4104DF}.Release|x64.ActiveCfg = Release|x64
|
||||
{67D0160C-0FE4-44B9-AC2E-82BBCF4104DF}.Release|x64.Build.0 = Release|x64
|
||||
{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}.Debug AVX2|ARM64.ActiveCfg = Debug Clang|ARM64
|
||||
{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}.Debug AVX2|x64.ActiveCfg = Debug AVX2|x64
|
||||
{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}.Debug AVX2|x64.Build.0 = Debug AVX2|x64
|
||||
{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}.Debug Clang AVX2|ARM64.ActiveCfg = Debug Clang|ARM64
|
||||
{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}.Debug Clang AVX2|x64.ActiveCfg = Debug Clang AVX2|x64
|
||||
{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}.Debug Clang AVX2|x64.Build.0 = Debug Clang AVX2|x64
|
||||
{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}.Debug Clang|ARM64.ActiveCfg = Debug Clang|ARM64
|
||||
{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}.Debug Clang|ARM64.Build.0 = Debug Clang|ARM64
|
||||
{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}.Debug Clang|x64.ActiveCfg = Debug Clang|x64
|
||||
{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}.Debug Clang|x64.Build.0 = Debug Clang|x64
|
||||
{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}.Debug|ARM64.ActiveCfg = Debug Clang|ARM64
|
||||
{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}.Debug|x64.Build.0 = Debug|x64
|
||||
{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}.Devel AVX2|ARM64.ActiveCfg = Devel Clang|ARM64
|
||||
{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}.Devel AVX2|x64.ActiveCfg = Devel AVX2|x64
|
||||
{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}.Devel AVX2|x64.Build.0 = Devel AVX2|x64
|
||||
{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}.Devel Clang AVX2|ARM64.ActiveCfg = Devel Clang|ARM64
|
||||
{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}.Devel Clang AVX2|x64.ActiveCfg = Devel Clang AVX2|x64
|
||||
{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}.Devel Clang AVX2|x64.Build.0 = Devel Clang AVX2|x64
|
||||
{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}.Devel Clang|ARM64.ActiveCfg = Devel Clang|ARM64
|
||||
{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}.Devel Clang|ARM64.Build.0 = Devel Clang|ARM64
|
||||
{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}.Devel Clang|x64.ActiveCfg = Devel Clang|x64
|
||||
{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}.Devel Clang|x64.Build.0 = Devel Clang|x64
|
||||
{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}.Devel|ARM64.ActiveCfg = Devel Clang|ARM64
|
||||
{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}.Devel|x64.ActiveCfg = Devel|x64
|
||||
{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}.Devel|x64.Build.0 = Devel|x64
|
||||
{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}.Release AVX2|ARM64.ActiveCfg = Release Clang|ARM64
|
||||
{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}.Release AVX2|x64.ActiveCfg = Release AVX2|x64
|
||||
{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}.Release AVX2|x64.Build.0 = Release AVX2|x64
|
||||
{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}.Release Clang AVX2|ARM64.ActiveCfg = Release Clang|ARM64
|
||||
{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}.Release Clang AVX2|x64.ActiveCfg = Release Clang AVX2|x64
|
||||
{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}.Release Clang AVX2|x64.Build.0 = Release Clang AVX2|x64
|
||||
{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}.Release Clang|ARM64.ActiveCfg = Release Clang|ARM64
|
||||
{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}.Release Clang|ARM64.Build.0 = Release Clang|ARM64
|
||||
{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}.Release Clang|x64.ActiveCfg = Release Clang|x64
|
||||
{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}.Release Clang|x64.Build.0 = Release Clang|x64
|
||||
{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}.Release|ARM64.ActiveCfg = Release Clang|ARM64
|
||||
{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}.Release|x64.ActiveCfg = Release|x64
|
||||
{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F}.Release|x64.Build.0 = Release|x64
|
||||
{1DD0B31F-37F0-4A36-A521-74133ACA4737}.Debug AVX2|ARM64.ActiveCfg = Debug Clang|ARM64
|
||||
{1DD0B31F-37F0-4A36-A521-74133ACA4737}.Debug AVX2|x64.ActiveCfg = Debug AVX2|x64
|
||||
{1DD0B31F-37F0-4A36-A521-74133ACA4737}.Debug AVX2|x64.Build.0 = Debug AVX2|x64
|
||||
|
@ -1008,7 +967,6 @@ Global
|
|||
{95DD0A0C-D14D-4CFF-A593-820EF26EFCC8} = {78EBE642-7A4D-4EA7-86BE-5639C6646C38}
|
||||
{E960DFDF-1BD3-4C29-B251-D1A0919C9B09} = {78EBE642-7A4D-4EA7-86BE-5639C6646C38}
|
||||
{67D0160C-0FE4-44B9-AC2E-82BBCF4104DF} = {78EBE642-7A4D-4EA7-86BE-5639C6646C38}
|
||||
{1E3D706C-1D95-4E1B-BDF2-CA3D0007DF7F} = {78EBE642-7A4D-4EA7-86BE-5639C6646C38}
|
||||
{1DD0B31F-37F0-4A36-A521-74133ACA4737} = {78EBE642-7A4D-4EA7-86BE-5639C6646C38}
|
||||
{8906836E-F06E-46E8-B11A-74E5E8C7B8FB} = {78EBE642-7A4D-4EA7-86BE-5639C6646C38}
|
||||
EndGlobalSection
|
||||
|
|
|
@ -112,9 +112,6 @@ if(WIN32)
|
|||
add_subdirectory(3rdparty/rainterface EXCLUDE_FROM_ALL)
|
||||
endif()
|
||||
|
||||
# Demangler for the debugger
|
||||
add_subdirectory(3rdparty/demangler EXCLUDE_FROM_ALL)
|
||||
|
||||
# Architecture-specific.
|
||||
if(_M_X86)
|
||||
add_subdirectory(3rdparty/zydis EXCLUDE_FROM_ALL)
|
||||
|
|
|
@ -19,8 +19,6 @@
|
|||
|
||||
#include "common/Console.h"
|
||||
|
||||
#include "demangler/demangler.h"
|
||||
|
||||
#include <QtGui/QClipboard>
|
||||
#include <QtWidgets/QMessageBox>
|
||||
#include <QtConcurrent/QtConcurrent>
|
||||
|
@ -141,7 +139,7 @@ CpuWidget::CpuWidget(QWidget* parent, DebugInterface& cpu)
|
|||
DebuggerSettingsManager::loadGameSettings(&m_savedAddressesModel);
|
||||
|
||||
connect(m_ui.memorySearchWidget, &MemorySearchWidget::addAddressToSavedAddressesList, this, &CpuWidget::addAddressToSavedAddressesList);
|
||||
connect(m_ui.memorySearchWidget, &MemorySearchWidget::goToAddressInDisassemblyView, [this](u32 address) { m_ui.disassemblyWidget->gotoAddress(address); });
|
||||
connect(m_ui.memorySearchWidget, &MemorySearchWidget::goToAddressInDisassemblyView, [this](u32 address) { m_ui.disassemblyWidget->gotoAddress(address); });
|
||||
connect(m_ui.memorySearchWidget, &MemorySearchWidget::goToAddressInMemoryView, m_ui.memoryviewWidget, &MemoryViewWidget::gotoAddress);
|
||||
connect(m_ui.memorySearchWidget, &MemorySearchWidget::switchToMemoryViewTab, [this]() { m_ui.tabWidget->setCurrentWidget(m_ui.tab_memory); });
|
||||
m_ui.memorySearchWidget->setCpu(&m_cpu);
|
||||
|
@ -598,20 +596,10 @@ void CpuWidget::updateFunctionList(bool whenEmpty)
|
|||
|
||||
m_ui.listFunctions->clear();
|
||||
|
||||
const auto demangler = demangler::CDemangler::createGcc();
|
||||
const QString filter = m_ui.txtFuncSearch->text().toLower();
|
||||
for (const auto& symbol : m_cpu.GetSymbolMap().GetAllSymbols(SymbolType::ST_FUNCTION))
|
||||
{
|
||||
QString symbolName = symbol.name.c_str();
|
||||
if (m_demangleFunctions)
|
||||
{
|
||||
symbolName = QString(demangler->demangleToString(symbol.name).c_str());
|
||||
|
||||
// If the name isn't mangled, or it doesn't understand, it'll return an empty string
|
||||
// Fall back to the original name if this is the case
|
||||
if (symbolName.isEmpty())
|
||||
symbolName = symbol.name.c_str();
|
||||
}
|
||||
|
||||
if (filter.size() && !symbolName.toLower().contains(filter))
|
||||
continue;
|
||||
|
@ -627,7 +615,6 @@ void CpuWidget::updateFunctionList(bool whenEmpty)
|
|||
}
|
||||
else
|
||||
{
|
||||
const auto demangler = demangler::CDemangler::createGcc();
|
||||
const QString filter = m_ui.txtFuncSearch->text().toLower();
|
||||
|
||||
m_ui.treeModules->clear();
|
||||
|
@ -641,12 +628,6 @@ void CpuWidget::updateFunctionList(bool whenEmpty)
|
|||
continue;
|
||||
|
||||
QString symbolName = QString(sym.name.c_str());
|
||||
if (m_demangleFunctions)
|
||||
{
|
||||
QString demangledName = QString(demangler->demangleToString(sym.name).c_str());
|
||||
if (!demangledName.isEmpty())
|
||||
symbolName = demangledName;
|
||||
}
|
||||
QTreeWidgetItem* functionItem = new QTreeWidgetItem(moduleItem, QStringList(QString("%0 %1").arg(FilledQStringFromValue(sym.address, 16)).arg(symbolName)));
|
||||
functionItem->setData(0, Qt::UserRole, sym.address);
|
||||
functions.append(functionItem);
|
||||
|
@ -765,18 +746,6 @@ void CpuWidget::onFuncListContextMenu(QPoint pos)
|
|||
|
||||
m_funclistContextMenu->addSeparator();
|
||||
}
|
||||
//: "Demangling" is the opposite of "Name mangling", which is a process where a compiler takes function names and combines them with other characteristics of the function (e.g. what types of data it accepts) to ensure they stay unique even when multiple functions exist with the same name (but different inputs / const-ness). See here: https://en.wikipedia.org/wiki/Name_mangling#C++
|
||||
QAction* demangleAction = new QAction(tr("Demangle Symbols"), m_ui.listFunctions);
|
||||
demangleAction->setCheckable(true);
|
||||
demangleAction->setChecked(m_demangleFunctions);
|
||||
|
||||
connect(demangleAction, &QAction::triggered, [this] {
|
||||
m_demangleFunctions = !m_demangleFunctions;
|
||||
m_ui.disassemblyWidget->setDemangle(m_demangleFunctions);
|
||||
updateFunctionList();
|
||||
});
|
||||
|
||||
m_funclistContextMenu->addAction(demangleAction);
|
||||
|
||||
if (m_cpu.getCpuType() == BREAKPOINT_IOP)
|
||||
{
|
||||
|
@ -839,21 +808,8 @@ void CpuWidget::onModuleTreeContextMenu(QPoint pos)
|
|||
m_moduleTreeContextMenu->addAction(gotoMemory);
|
||||
}
|
||||
|
||||
//: "Demangling" is the opposite of "Name mangling", which is a process where a compiler takes function names and combines them with other characteristics of the function (e.g. what types of data it accepts) to ensure they stay unique even when multiple functions exist with the same name (but different inputs / const-ness). See here: https://en.wikipedia.org/wiki/Name_mangling#C++
|
||||
QAction* demangleAction = new QAction(tr("Demangle Symbols"), m_ui.treeModules);
|
||||
demangleAction->setCheckable(true);
|
||||
demangleAction->setChecked(m_demangleFunctions);
|
||||
|
||||
connect(demangleAction, &QAction::triggered, [this] {
|
||||
m_demangleFunctions = !m_demangleFunctions;
|
||||
m_ui.disassemblyWidget->setDemangle(m_demangleFunctions);
|
||||
updateFunctionList();
|
||||
});
|
||||
|
||||
m_moduleTreeContextMenu->addSeparator();
|
||||
|
||||
m_moduleTreeContextMenu->addAction(demangleAction);
|
||||
|
||||
QAction* moduleViewAction = new QAction(tr("Module Tree"), m_ui.treeModules);
|
||||
moduleViewAction->setCheckable(true);
|
||||
moduleViewAction->setChecked(m_moduleView);
|
||||
|
|
|
@ -66,7 +66,6 @@ public slots:
|
|||
void updateFunctionList(bool whenEmpty = false);
|
||||
void onFuncListContextMenu(QPoint pos);
|
||||
void onFuncListDoubleClick(QListWidgetItem* item);
|
||||
bool getDemangleFunctions() const { return m_demangleFunctions; }
|
||||
void onModuleTreeContextMenu(QPoint pos);
|
||||
void onModuleTreeDoubleClick(QTreeWidgetItem* item);
|
||||
void refreshDebugger();
|
||||
|
@ -93,6 +92,5 @@ private:
|
|||
StackModel m_stackModel;
|
||||
SavedAddressesModel m_savedAddressesModel;
|
||||
|
||||
bool m_demangleFunctions = true;
|
||||
bool m_moduleView = true;
|
||||
};
|
||||
|
|
|
@ -7,7 +7,6 @@
|
|||
#include "DebugTools/DisassemblyManager.h"
|
||||
#include "DebugTools/Breakpoints.h"
|
||||
#include "DebugTools/MipsAssembler.h"
|
||||
#include "demangler/demangler.h"
|
||||
|
||||
#include "QtUtils.h"
|
||||
#include "QtHost.h"
|
||||
|
@ -749,7 +748,6 @@ inline QString DisassemblyWidget::DisassemblyStringFromAddress(u32 address, QFon
|
|||
{
|
||||
isFunctionNoReturn = m_cpu->GetSymbolMap().GetFunctionNoReturn(address);
|
||||
}
|
||||
const auto demangler = demangler::CDemangler::createGcc();
|
||||
const bool showOpcode = m_showInstructionOpcode && m_cpu->isAlive();
|
||||
|
||||
QString lineString;
|
||||
|
@ -777,19 +775,7 @@ inline QString DisassemblyWidget::DisassemblyStringFromAddress(u32 address, QFon
|
|||
{
|
||||
// We want this text elided
|
||||
QFontMetrics metric(font);
|
||||
QString symbolString;
|
||||
if (m_demangleFunctions)
|
||||
{
|
||||
symbolString = QString::fromStdString(demangler->demangleToString(addressSymbol));
|
||||
if (symbolString.isEmpty())
|
||||
{
|
||||
symbolString = QString::fromStdString(addressSymbol);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
symbolString = QString::fromStdString(addressSymbol);
|
||||
}
|
||||
QString symbolString = QString::fromStdString(addressSymbol);
|
||||
|
||||
lineString = lineString.arg(metric.elidedText(symbolString, Qt::ElideRight, (selected ? 32 : 7) * font.pointSize()));
|
||||
}
|
||||
|
|
|
@ -42,7 +42,6 @@
|
|||
<AdditionalIncludeDirectories>%(AdditionalIncludeDirectories);$(SolutionDir)3rdparty\lzma\include</AdditionalIncludeDirectories>
|
||||
<AdditionalIncludeDirectories>%(AdditionalIncludeDirectories);$(SolutionDir)3rdparty\simpleini\include</AdditionalIncludeDirectories>
|
||||
<AdditionalIncludeDirectories>%(AdditionalIncludeDirectories);$(SolutionDir)3rdparty\imgui\include</AdditionalIncludeDirectories>
|
||||
<AdditionalIncludeDirectories>%(AdditionalIncludeDirectories);$(SolutionDir)3rdparty\demangler\include</AdditionalIncludeDirectories>
|
||||
<AdditionalIncludeDirectories>%(AdditionalIncludeDirectories);$(SolutionDir)3rdparty\cpuinfo\include</AdditionalIncludeDirectories>
|
||||
<AdditionalIncludeDirectories>%(AdditionalIncludeDirectories);$(SolutionDir)3rdparty\fast_float\include</AdditionalIncludeDirectories>
|
||||
<AdditionalIncludeDirectories>%(AdditionalIncludeDirectories);$(SolutionDir)pcsx2</AdditionalIncludeDirectories>
|
||||
|
@ -80,9 +79,6 @@
|
|||
<ProjectReference Include="..\3rdparty\lzma\lzma.vcxproj">
|
||||
<Project>{a4323327-3f2b-4271-83d9-7f9a3c66b6b2}</Project>
|
||||
</ProjectReference>
|
||||
<ProjectReference Include="..\3rdparty\demangler\demangler.vcxproj">
|
||||
<Project>{1e3d706c-1d95-4e1b-bdf2-ca3d0007df7f}</Project>
|
||||
</ProjectReference>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Manifest Include="..\pcsx2\windows\PCSX2.manifest" />
|
||||
|
|
|
@ -1138,7 +1138,6 @@ target_link_libraries(PCSX2_FLAGS INTERFACE
|
|||
cubeb
|
||||
rcheevos
|
||||
discord-rpc
|
||||
demangler
|
||||
simpleini
|
||||
freesurround
|
||||
SDL2::SDL2
|
||||
|
|
Loading…
Reference in New Issue