antlr4cpp on Windows

- Solved all compilation issues. Updated the antlr4cpp library project. At the moment we only build a static lib. Need to add exports for a DLL. Since we want this library to be compatible with VS 2013 still, we cannot use std::rethrow_with_nested(), hence we do a simple unnested throw in such cases. Starting with VS 2015 this works fully then.
- Added demo application.
- Added parser generation script.
This commit is contained in:
Mike Lischke 2016-04-23 11:03:30 +02:00
parent e85385785e
commit b2daab9477
39 changed files with 1456 additions and 1087 deletions

View File

@ -0,0 +1,187 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup Label="ProjectConfigurations">
<ProjectConfiguration Include="Debug|Win32">
<Configuration>Debug</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Debug|x64">
<Configuration>Debug</Configuration>
<Platform>x64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|Win32">
<Configuration>Release</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|x64">
<Configuration>Release</Configuration>
<Platform>x64</Platform>
</ProjectConfiguration>
</ItemGroup>
<PropertyGroup Label="Globals">
<ProjectGuid>{24EC5104-7402-4C76-B66B-27ADBE062D68}</ProjectGuid>
<Keyword>Win32Proj</Keyword>
<RootNamespace>antlr4cppdemo</RootNamespace>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
<PlatformToolset>v120</PlatformToolset>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
<PlatformToolset>v120</PlatformToolset>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<PlatformToolset>v120</PlatformToolset>
<WholeProgramOptimization>true</WholeProgramOptimization>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<PlatformToolset>v120</PlatformToolset>
<WholeProgramOptimization>true</WholeProgramOptimization>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
<ImportGroup Label="ExtensionSettings">
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<PropertyGroup Label="UserMacros" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<LinkIncremental>true</LinkIncremental>
<OutDir>$(SolutionDir)bin\$(PlatformTarget)\$(Configuration)\</OutDir>
<IntDir>$(SolutionDir)obj\$(PlatformTarget)\$(Configuration)\$(ProjectName)\</IntDir>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<LinkIncremental>true</LinkIncremental>
<OutDir>$(SolutionDir)bin\$(PlatformTarget)\$(Configuration)\</OutDir>
<IntDir>$(SolutionDir)obj\$(PlatformTarget)\$(Configuration)\$(ProjectName)\</IntDir>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<LinkIncremental>false</LinkIncremental>
<OutDir>$(SolutionDir)bin\$(PlatformTarget)\$(Configuration)\</OutDir>
<IntDir>$(SolutionDir)obj\$(PlatformTarget)\$(Configuration)\$(ProjectName)\</IntDir>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<LinkIncremental>false</LinkIncremental>
<OutDir>$(SolutionDir)bin\$(PlatformTarget)\$(Configuration)\</OutDir>
<IntDir>$(SolutionDir)obj\$(PlatformTarget)\$(Configuration)\$(ProjectName)\</IntDir>
</PropertyGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<ClCompile>
<PrecompiledHeader>
</PrecompiledHeader>
<WarningLevel>Level3</WarningLevel>
<Optimization>Disabled</Optimization>
<PreprocessorDefinitions>WIN32;_DEBUG;_CONSOLE;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<SDLCheck>true</SDLCheck>
<AdditionalIncludeDirectories>$(SolutionDir)..\generated;$(SolutionDir)..\..\runtime;$(SolutionDir)..\..\runtime\atn;$(SolutionDir)..\..\runtime\dfa;$(SolutionDir)..\..\runtime\misc;$(SolutionDir)..\..\runtime\support;$(SolutionDir)..\..\runtime\tree;$(SolutionDir)..\..\runtime\tree\xpath;$(SolutionDir)..\..\runtime\tree\pattern;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<ForcedIncludeFiles>antlrcpp-Prefix.h</ForcedIncludeFiles>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<ClCompile>
<PrecompiledHeader>
</PrecompiledHeader>
<WarningLevel>Level3</WarningLevel>
<Optimization>Disabled</Optimization>
<PreprocessorDefinitions>WIN32;_DEBUG;_CONSOLE;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<SDLCheck>true</SDLCheck>
<AdditionalIncludeDirectories>$(SolutionDir)..\generated;$(SolutionDir)..\..\runtime;$(SolutionDir)..\..\runtime\atn;$(SolutionDir)..\..\runtime\dfa;$(SolutionDir)..\..\runtime\misc;$(SolutionDir)..\..\runtime\support;$(SolutionDir)..\..\runtime\tree;$(SolutionDir)..\..\runtime\tree\xpath;$(SolutionDir)..\..\runtime\tree\pattern;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<ForcedIncludeFiles>antlrcpp-Prefix.h</ForcedIncludeFiles>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<PrecompiledHeader>
</PrecompiledHeader>
<Optimization>MaxSpeed</Optimization>
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<PreprocessorDefinitions>WIN32;NDEBUG;_CONSOLE;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<SDLCheck>true</SDLCheck>
<AdditionalIncludeDirectories>$(SolutionDir)..\generated;$(SolutionDir)..\..\runtime;$(SolutionDir)..\..\runtime\atn;$(SolutionDir)..\..\runtime\dfa;$(SolutionDir)..\..\runtime\misc;$(SolutionDir)..\..\runtime\support;$(SolutionDir)..\..\runtime\tree;$(SolutionDir)..\..\runtime\tree\xpath;$(SolutionDir)..\..\runtime\tree\pattern;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<ForcedIncludeFiles>antlrcpp-Prefix.h</ForcedIncludeFiles>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<PrecompiledHeader>
</PrecompiledHeader>
<Optimization>MaxSpeed</Optimization>
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<PreprocessorDefinitions>WIN32;NDEBUG;_CONSOLE;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<SDLCheck>true</SDLCheck>
<AdditionalIncludeDirectories>$(SolutionDir)..\generated;$(SolutionDir)..\..\runtime;$(SolutionDir)..\..\runtime\atn;$(SolutionDir)..\..\runtime\dfa;$(SolutionDir)..\..\runtime\misc;$(SolutionDir)..\..\runtime\support;$(SolutionDir)..\..\runtime\tree;$(SolutionDir)..\..\runtime\tree\xpath;$(SolutionDir)..\..\runtime\tree\pattern;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<ForcedIncludeFiles>antlrcpp-Prefix.h</ForcedIncludeFiles>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
</Link>
</ItemDefinitionGroup>
<ItemGroup>
<ClCompile Include="..\..\generated\TLexer.cpp" />
<ClCompile Include="..\..\generated\TParser.cpp" />
<ClCompile Include="..\..\generated\TParserBaseListener.cpp" />
<ClCompile Include="..\..\generated\TParserBaseVisitor.cpp" />
<ClCompile Include="..\..\generated\TParserListener.cpp" />
<ClCompile Include="..\..\generated\TParserVisitor.cpp" />
<ClCompile Include="main.cpp" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\antlr4cpp.vcxproj">
<Project>{a9762991-1b57-4dce-90c0-ee42b96947be}</Project>
</ProjectReference>
</ItemGroup>
<ItemGroup>
<ClInclude Include="..\..\..\runtime\antlrcpp-Prefix.h" />
<ClInclude Include="..\..\generated\TLexer.h" />
<ClInclude Include="..\..\generated\TParser.h" />
<ClInclude Include="..\..\generated\TParserBaseListener.h" />
<ClInclude Include="..\..\generated\TParserBaseVisitor.h" />
<ClInclude Include="..\..\generated\TParserListener.h" />
<ClInclude Include="..\..\generated\TParserVisitor.h" />
</ItemGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
</ImportGroup>
</Project>

View File

@ -0,0 +1,66 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup>
<Filter Include="Source Files">
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
<Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
</Filter>
<Filter Include="Header Files">
<UniqueIdentifier>{93995380-89BD-4b04-88EB-625FBE52EBFB}</UniqueIdentifier>
<Extensions>h;hh;hpp;hxx;hm;inl;inc;xsd</Extensions>
</Filter>
<Filter Include="Resource Files">
<UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier>
<Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms</Extensions>
</Filter>
<Filter Include="generated">
<UniqueIdentifier>{ef397b7b-1192-4d44-93ed-fadaec7622e8}</UniqueIdentifier>
</Filter>
</ItemGroup>
<ItemGroup>
<ClCompile Include="main.cpp">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="..\..\generated\TParser.cpp">
<Filter>generated</Filter>
</ClCompile>
<ClCompile Include="..\..\generated\TParserBaseListener.cpp">
<Filter>generated</Filter>
</ClCompile>
<ClCompile Include="..\..\generated\TParserBaseVisitor.cpp">
<Filter>generated</Filter>
</ClCompile>
<ClCompile Include="..\..\generated\TParserListener.cpp">
<Filter>generated</Filter>
</ClCompile>
<ClCompile Include="..\..\generated\TParserVisitor.cpp">
<Filter>generated</Filter>
</ClCompile>
<ClCompile Include="..\..\generated\TLexer.cpp">
<Filter>generated</Filter>
</ClCompile>
</ItemGroup>
<ItemGroup>
<ClInclude Include="..\..\..\runtime\antlrcpp-Prefix.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="..\..\generated\TLexer.h">
<Filter>generated</Filter>
</ClInclude>
<ClInclude Include="..\..\generated\TParser.h">
<Filter>generated</Filter>
</ClInclude>
<ClInclude Include="..\..\generated\TParserBaseListener.h">
<Filter>generated</Filter>
</ClInclude>
<ClInclude Include="..\..\generated\TParserBaseVisitor.h">
<Filter>generated</Filter>
</ClInclude>
<ClInclude Include="..\..\generated\TParserListener.h">
<Filter>generated</Filter>
</ClInclude>
<ClInclude Include="..\..\generated\TParserVisitor.h">
<Filter>generated</Filter>
</ClInclude>
</ItemGroup>
</Project>

View File

@ -0,0 +1,31 @@
//
// main.cpp
// antlr4-cpp-demo
//
// Created by Mike Lischke on 13.03.16.
//
#include <iostream>
#include "ANTLRInputStream.h"
#include "CommonTokenStream.h"
#include "TLexer.h"
#include "TParser.h"
#include "Strings.h"
using namespace antlrcpptest;
using namespace org::antlr::v4::runtime;
int main(int argc, const char * argv[]) {
ANTLRInputStream input(L"divideŴ and conquer");
TLexer lexer(&input);
CommonTokenStream tokens(&lexer);
TParser parser(&tokens);
std::shared_ptr<tree::ParseTree> tree = parser.main();
std::cout << antlrcpp::ws2s(tree->toStringTree(&parser)) << std::endl;
return 0;
}

View File

@ -1,18 +1,36 @@

Microsoft Visual Studio Solution File, Format Version 11.00
# Visual Studio 2010
Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 2013
VisualStudioVersion = 12.0.40629.0
MinimumVisualStudioVersion = 10.0.40219.1
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "antlr4cpp", "antlr4cpp.vcxproj", "{A9762991-1B57-4DCE-90C0-EE42B96947BE}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "antlr4-cpp-demo", "antlr4-cpp-demo\antlr4-cpp-demo.vcxproj", "{24EC5104-7402-4C76-B66B-27ADBE062D68}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Win32 = Debug|Win32
Debug|x64 = Debug|x64
Release|Win32 = Release|Win32
Release|x64 = Release|x64
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{A9762991-1B57-4DCE-90C0-EE42B96947BE}.Debug|Win32.ActiveCfg = Debug|Win32
{A9762991-1B57-4DCE-90C0-EE42B96947BE}.Debug|Win32.Build.0 = Debug|Win32
{A9762991-1B57-4DCE-90C0-EE42B96947BE}.Debug|x64.ActiveCfg = Debug|x64
{A9762991-1B57-4DCE-90C0-EE42B96947BE}.Debug|x64.Build.0 = Debug|x64
{A9762991-1B57-4DCE-90C0-EE42B96947BE}.Release|Win32.ActiveCfg = Release|Win32
{A9762991-1B57-4DCE-90C0-EE42B96947BE}.Release|Win32.Build.0 = Release|Win32
{A9762991-1B57-4DCE-90C0-EE42B96947BE}.Release|x64.ActiveCfg = Release|x64
{A9762991-1B57-4DCE-90C0-EE42B96947BE}.Release|x64.Build.0 = Release|x64
{24EC5104-7402-4C76-B66B-27ADBE062D68}.Debug|Win32.ActiveCfg = Debug|Win32
{24EC5104-7402-4C76-B66B-27ADBE062D68}.Debug|Win32.Build.0 = Debug|Win32
{24EC5104-7402-4C76-B66B-27ADBE062D68}.Debug|x64.ActiveCfg = Debug|x64
{24EC5104-7402-4C76-B66B-27ADBE062D68}.Debug|x64.Build.0 = Debug|x64
{24EC5104-7402-4C76-B66B-27ADBE062D68}.Release|Win32.ActiveCfg = Release|Win32
{24EC5104-7402-4C76-B66B-27ADBE062D68}.Release|Win32.Build.0 = Release|Win32
{24EC5104-7402-4C76-B66B-27ADBE062D68}.Release|x64.ActiveCfg = Release|x64
{24EC5104-7402-4C76-B66B-27ADBE062D68}.Release|x64.Build.0 = Release|x64
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE

View File

@ -5,10 +5,18 @@
<Configuration>Debug</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Debug|x64">
<Configuration>Debug</Configuration>
<Platform>x64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|Win32">
<Configuration>Release</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|x64">
<Configuration>Release</Configuration>
<Platform>x64</Platform>
</ProjectConfiguration>
</ItemGroup>
<PropertyGroup Label="Globals">
<ProjectGuid>{A9762991-1B57-4DCE-90C0-EE42B96947BE}</ProjectGuid>
@ -17,13 +25,26 @@
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
<ConfigurationType>DynamicLibrary</ConfigurationType>
<ConfigurationType>StaticLibrary</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v120</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v120</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
<ConfigurationType>DynamicLibrary</ConfigurationType>
<ConfigurationType>StaticLibrary</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<WholeProgramOptimization>true</WholeProgramOptimization>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v120</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<WholeProgramOptimization>true</WholeProgramOptimization>
<CharacterSet>Unicode</CharacterSet>
@ -35,25 +56,60 @@
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<PropertyGroup Label="UserMacros" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<LinkIncremental>true</LinkIncremental>
<OutDir>$(SolutionDir)bin\$(PlatformTarget)\$(Configuration)\</OutDir>
<IntDir>$(SolutionDir)obj\$(PlatformTarget)\$(Configuration)\$(ProjectName)\</IntDir>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<LinkIncremental>true</LinkIncremental>
<OutDir>$(SolutionDir)bin\$(PlatformTarget)\$(Configuration)\</OutDir>
<IntDir>$(SolutionDir)obj\$(PlatformTarget)\$(Configuration)\$(ProjectName)\</IntDir>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<LinkIncremental>false</LinkIncremental>
<OutDir>$(SolutionDir)bin\$(PlatformTarget)\$(Configuration)\</OutDir>
<IntDir>$(SolutionDir)obj\$(PlatformTarget)\$(Configuration)\$(ProjectName)\</IntDir>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<LinkIncremental>false</LinkIncremental>
<OutDir>$(SolutionDir)bin\$(PlatformTarget)\$(Configuration)\</OutDir>
<IntDir>$(SolutionDir)obj\$(PlatformTarget)\$(Configuration)\$(ProjectName)\</IntDir>
</PropertyGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<ClCompile>
<PrecompiledHeader>
</PrecompiledHeader>
<PrecompiledHeader>Use</PrecompiledHeader>
<WarningLevel>Level3</WarningLevel>
<Optimization>Disabled</Optimization>
<PreprocessorDefinitions>WIN32;_DEBUG;_WINDOWS;_USRDLL;ANTLR4CPP_EXPORTS;%(PreprocessorDefinitions);WINDOWS</PreprocessorDefinitions>
<AdditionalIncludeDirectories>$(ProjectDir)\..\antlrcpp;$(ProjectDir)\..\org\antlr\v4\runtime;$(ProjectDir)\..\org\antlr\v4\runtime\atn;$(ProjectDir)\..\org\antlr\v4\runtime\dfa;$(ProjectDir)\..\org\antlr\v4\runtime\misc;$(ProjectDir)\..\org\antlr\v4\runtime\tree;$(ProjectDir)\..\org\antlr\v4\runtime\tree\xpath;$(ProjectDir)\..\org\antlr\v4\runtime\tree\pattern;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<MultiProcessorCompilation>false</MultiProcessorCompilation>
<PreprocessorDefinitions>ANTLR4CPP_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<AdditionalIncludeDirectories>$(SolutionDir)..\..\runtime;$(SolutionDir)..\..\runtime\atn;$(SolutionDir)..\..\runtime\dfa;$(SolutionDir)..\..\runtime\misc;$(SolutionDir)..\..\runtime\support;$(SolutionDir)..\..\runtime\tree;$(SolutionDir)..\..\runtime\tree\xpath;$(SolutionDir)..\..\runtime\tree\pattern;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<PrecompiledHeaderFile>antlrcpp-Prefix.h</PrecompiledHeaderFile>
<ForcedIncludeFiles>antlrcpp-Prefix.h</ForcedIncludeFiles>
</ClCompile>
<Link>
<SubSystem>Windows</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<ClCompile>
<PrecompiledHeader>Use</PrecompiledHeader>
<WarningLevel>Level3</WarningLevel>
<Optimization>Disabled</Optimization>
<PreprocessorDefinitions>ANTLR4CPP_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<AdditionalIncludeDirectories>$(SolutionDir)..\..\runtime;$(SolutionDir)..\..\runtime\atn;$(SolutionDir)..\..\runtime\dfa;$(SolutionDir)..\..\runtime\misc;$(SolutionDir)..\..\runtime\support;$(SolutionDir)..\..\runtime\tree;$(SolutionDir)..\..\runtime\tree\xpath;$(SolutionDir)..\..\runtime\tree\pattern;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<PrecompiledHeaderFile>antlrcpp-Prefix.h</PrecompiledHeaderFile>
<ForcedIncludeFiles>antlrcpp-Prefix.h</ForcedIncludeFiles>
</ClCompile>
<Link>
<SubSystem>Windows</SubSystem>
@ -63,12 +119,33 @@
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<PrecompiledHeader>
</PrecompiledHeader>
<PrecompiledHeader>Use</PrecompiledHeader>
<Optimization>MaxSpeed</Optimization>
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;ANTLR4CPP_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<PreprocessorDefinitions>ANTLR4CPP_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<AdditionalIncludeDirectories>$(SolutionDir)..\..\runtime;$(SolutionDir)..\..\runtime\atn;$(SolutionDir)..\..\runtime\dfa;$(SolutionDir)..\..\runtime\misc;$(SolutionDir)..\..\runtime\support;$(SolutionDir)..\..\runtime\tree;$(SolutionDir)..\..\runtime\tree\xpath;$(SolutionDir)..\..\runtime\tree\pattern;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<PrecompiledHeaderFile>antlrcpp-Prefix.h</PrecompiledHeaderFile>
<ForcedIncludeFiles>antlrcpp-Prefix.h</ForcedIncludeFiles>
</ClCompile>
<Link>
<SubSystem>Windows</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<PrecompiledHeader>Use</PrecompiledHeader>
<Optimization>MaxSpeed</Optimization>
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<PreprocessorDefinitions>ANTLR4CPP_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<AdditionalIncludeDirectories>$(SolutionDir)..\..\runtime;$(SolutionDir)..\..\runtime\atn;$(SolutionDir)..\..\runtime\dfa;$(SolutionDir)..\..\runtime\misc;$(SolutionDir)..\..\runtime\support;$(SolutionDir)..\..\runtime\tree;$(SolutionDir)..\..\runtime\tree\xpath;$(SolutionDir)..\..\runtime\tree\pattern;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<PrecompiledHeaderFile>antlrcpp-Prefix.h</PrecompiledHeaderFile>
<ForcedIncludeFiles>antlrcpp-Prefix.h</ForcedIncludeFiles>
</ClCompile>
<Link>
<SubSystem>Windows</SubSystem>
@ -78,295 +155,259 @@
</Link>
</ItemDefinitionGroup>
<ItemGroup>
<ClCompile Include="..\antlrcpp\Arrays.cpp" />
<ClCompile Include="..\antlrcpp\CPPUtils.cpp" />
<ClCompile Include="..\antlrcpp\StringBuilder.cpp" />
<ClCompile Include="..\antlrcpp\Strings.cpp" />
<ClCompile Include="..\antlrcpp\UUID.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\ANTLRErrorListener.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\ANTLRErrorStrategy.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\ANTLRFileStream.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\ANTLRInputStream.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\AbstractPredicateTransition.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\ActionTransition.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\ArrayPredictionContext.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\ATN.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\ATNConfig.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\ATNConfigSet.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\ATNDeserializationOptions.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\ATNDeserializer.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\ATNSerializer.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\ATNSimulator.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\ATNState.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\ATNType.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\AtomTransition.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\BasicBlockStartState.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\BasicState.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\BlockEndState.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\BlockStartState.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\DecisionState.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\EmptyPredictionContext.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\EpsilonTransition.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\LexerATNConfig.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\LexerATNSimulator.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\LL1Analyzer.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\LoopEndState.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\NotSetTransition.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\OrderedATNConfigSet.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\ParserATNSimulator.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\PlusBlockStartState.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\PlusLoopbackState.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\PrecedencePredicateTransition.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\PredicateTransition.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\PredictionContext.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\PredictionContextCache.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\PredictionMode.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\RangeTransition.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\RuleStartState.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\RuleStopState.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\RuleTransition.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\SemanticContext.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\SetTransition.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\SingletonPredictionContext.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\StarBlockStartState.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\StarLoopbackState.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\StarLoopEntryState.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\TokensStartState.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\Transition.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\atn\WildcardTransition.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\BailErrorStrategy.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\BaseErrorListener.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\BufferedTokenStream.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\CharStream.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\CommonToken.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\CommonTokenFactory.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\CommonTokenStream.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\ConsoleErrorListener.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\DefaultErrorStrategy.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\dfa\DFA.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\dfa\DFASerializer.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\dfa\DFAState.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\dfa\LexerDFASerializer.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\DiagnosticErrorListener.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\Exceptions.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\FailedPredicateException.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\InputMismatchException.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\InterpreterRuleContext.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\IntStream.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\Lexer.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\LexerInterpreter.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\LexerNoViableAltException.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\ListTokenSource.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\misc\AbstractEqualityComparator.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\misc\EqualityComparator.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\misc\GraphicsSupport.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\misc\Interval.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\misc\IntervalSet.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\misc\IntSet.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\misc\LogManager.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\misc\MultiMap.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\misc\MurmurHash.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\misc\NotNull.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\misc\ObjectEqualityComparator.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\misc\OrderedHashSet.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\misc\ParseCancellationException.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\misc\TestRig.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\misc\Utils.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\NoViableAltException.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\Parser.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\ParserInterpreter.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\ParserRuleContext.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\ProxyErrorListener.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\RecognitionException.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\RuleContext.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\Token.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\TokenFactory.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\TokenSource.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\TokenStream.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\TokenStreamRewriter.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\tree\AbstractParseTreeVisitor.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\tree\ErrorNode.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\tree\ErrorNodeImpl.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\tree\ParseTree.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\tree\ParseTreeListener.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\tree\ParseTreeProperty.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\tree\ParseTreeVisitor.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\tree\ParseTreeWalker.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\tree\pattern\Chunk.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\tree\pattern\ParseTreeMatch.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\tree\pattern\ParseTreePattern.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\tree\pattern\ParseTreePatternMatcher.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\tree\pattern\RuleTagToken.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\tree\pattern\TagChunk.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\tree\pattern\TextChunk.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\tree\pattern\TokenTagToken.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\tree\RuleNode.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\tree\SyntaxTree.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\tree\TerminalNode.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\tree\TerminalNodeImpl.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\tree\Tree.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\tree\Trees.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\tree\xpath\XPath.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\tree\xpath\XPathElement.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\tree\xpath\XPathLexer.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\tree\xpath\XPathLexerErrorListener.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\tree\xpath\XPathRuleAnywhereElement.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\tree\xpath\XPathRuleElement.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\tree\xpath\XPathTokenAnywhereElement.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\tree\xpath\XPathTokenElement.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\tree\xpath\XPathWildcardAnywhereElement.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\tree\xpath\XPathWildcardElement.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\UnbufferedCharStream.cpp" />
<ClCompile Include="..\org\antlr\v4\runtime\WritableToken.cpp" />
<ClCompile Include="..\..\runtime\ANTLRErrorListener.cpp" />
<ClCompile Include="..\..\runtime\ANTLRErrorStrategy.cpp" />
<ClCompile Include="..\..\runtime\ANTLRFileStream.cpp" />
<ClCompile Include="..\..\runtime\ANTLRInputStream.cpp" />
<ClCompile Include="..\..\runtime\atn\AbstractPredicateTransition.cpp" />
<ClCompile Include="..\..\runtime\atn\ActionTransition.cpp" />
<ClCompile Include="..\..\runtime\atn\ArrayPredictionContext.cpp" />
<ClCompile Include="..\..\runtime\atn\ATN.cpp" />
<ClCompile Include="..\..\runtime\atn\ATNConfig.cpp" />
<ClCompile Include="..\..\runtime\atn\ATNConfigSet.cpp" />
<ClCompile Include="..\..\runtime\atn\ATNDeserializationOptions.cpp" />
<ClCompile Include="..\..\runtime\atn\ATNDeserializer.cpp" />
<ClCompile Include="..\..\runtime\atn\ATNSerializer.cpp" />
<ClCompile Include="..\..\runtime\atn\ATNSimulator.cpp" />
<ClCompile Include="..\..\runtime\atn\ATNState.cpp" />
<ClCompile Include="..\..\runtime\atn\ATNType.cpp" />
<ClCompile Include="..\..\runtime\atn\AtomTransition.cpp" />
<ClCompile Include="..\..\runtime\atn\BasicBlockStartState.cpp" />
<ClCompile Include="..\..\runtime\atn\BasicState.cpp" />
<ClCompile Include="..\..\runtime\atn\BlockEndState.cpp" />
<ClCompile Include="..\..\runtime\atn\BlockStartState.cpp" />
<ClCompile Include="..\..\runtime\atn\ConfigLookup.cpp" />
<ClCompile Include="..\..\runtime\atn\DecisionState.cpp" />
<ClCompile Include="..\..\runtime\atn\EmptyPredictionContext.cpp" />
<ClCompile Include="..\..\runtime\atn\EpsilonTransition.cpp" />
<ClCompile Include="..\..\runtime\atn\LexerATNConfig.cpp" />
<ClCompile Include="..\..\runtime\atn\LexerATNSimulator.cpp" />
<ClCompile Include="..\..\runtime\atn\LL1Analyzer.cpp" />
<ClCompile Include="..\..\runtime\atn\LoopEndState.cpp" />
<ClCompile Include="..\..\runtime\atn\NotSetTransition.cpp" />
<ClCompile Include="..\..\runtime\atn\OrderedATNConfigSet.cpp" />
<ClCompile Include="..\..\runtime\atn\ParserATNSimulator.cpp" />
<ClCompile Include="..\..\runtime\atn\PlusBlockStartState.cpp" />
<ClCompile Include="..\..\runtime\atn\PlusLoopbackState.cpp" />
<ClCompile Include="..\..\runtime\atn\PrecedencePredicateTransition.cpp" />
<ClCompile Include="..\..\runtime\atn\PredicateTransition.cpp" />
<ClCompile Include="..\..\runtime\atn\PredictionContext.cpp" />
<ClCompile Include="..\..\runtime\atn\PredictionMode.cpp" />
<ClCompile Include="..\..\runtime\atn\RangeTransition.cpp" />
<ClCompile Include="..\..\runtime\atn\RuleStartState.cpp" />
<ClCompile Include="..\..\runtime\atn\RuleStopState.cpp" />
<ClCompile Include="..\..\runtime\atn\RuleTransition.cpp" />
<ClCompile Include="..\..\runtime\atn\SemanticContext.cpp" />
<ClCompile Include="..\..\runtime\atn\SetTransition.cpp" />
<ClCompile Include="..\..\runtime\atn\SingletonPredictionContext.cpp" />
<ClCompile Include="..\..\runtime\atn\StarBlockStartState.cpp" />
<ClCompile Include="..\..\runtime\atn\StarLoopbackState.cpp" />
<ClCompile Include="..\..\runtime\atn\StarLoopEntryState.cpp" />
<ClCompile Include="..\..\runtime\atn\TokensStartState.cpp" />
<ClCompile Include="..\..\runtime\atn\Transition.cpp" />
<ClCompile Include="..\..\runtime\atn\WildcardTransition.cpp" />
<ClCompile Include="..\..\runtime\BailErrorStrategy.cpp" />
<ClCompile Include="..\..\runtime\BaseErrorListener.cpp" />
<ClCompile Include="..\..\runtime\BufferedTokenStream.cpp" />
<ClCompile Include="..\..\runtime\CharStream.cpp" />
<ClCompile Include="..\..\runtime\CommonToken.cpp" />
<ClCompile Include="..\..\runtime\CommonTokenFactory.cpp" />
<ClCompile Include="..\..\runtime\CommonTokenStream.cpp" />
<ClCompile Include="..\..\runtime\ConsoleErrorListener.cpp" />
<ClCompile Include="..\..\runtime\DefaultErrorStrategy.cpp" />
<ClCompile Include="..\..\runtime\dfa\DFA.cpp" />
<ClCompile Include="..\..\runtime\dfa\DFASerializer.cpp" />
<ClCompile Include="..\..\runtime\dfa\DFAState.cpp" />
<ClCompile Include="..\..\runtime\dfa\LexerDFASerializer.cpp" />
<ClCompile Include="..\..\runtime\DiagnosticErrorListener.cpp" />
<ClCompile Include="..\..\runtime\Exceptions.cpp" />
<ClCompile Include="..\..\runtime\FailedPredicateException.cpp" />
<ClCompile Include="..\..\runtime\InputMismatchException.cpp" />
<ClCompile Include="..\..\runtime\InterpreterRuleContext.cpp" />
<ClCompile Include="..\..\runtime\IntStream.cpp" />
<ClCompile Include="..\..\runtime\Lexer.cpp" />
<ClCompile Include="..\..\runtime\LexerInterpreter.cpp" />
<ClCompile Include="..\..\runtime\LexerNoViableAltException.cpp" />
<ClCompile Include="..\..\runtime\ListTokenSource.cpp" />
<ClCompile Include="..\..\runtime\misc\Interval.cpp" />
<ClCompile Include="..\..\runtime\misc\IntervalSet.cpp" />
<ClCompile Include="..\..\runtime\misc\MurmurHash.cpp" />
<ClCompile Include="..\..\runtime\misc\TestRig.cpp" />
<ClCompile Include="..\..\runtime\NoViableAltException.cpp" />
<ClCompile Include="..\..\runtime\Parser.cpp" />
<ClCompile Include="..\..\runtime\ParserInterpreter.cpp" />
<ClCompile Include="..\..\runtime\ParserRuleContext.cpp" />
<ClCompile Include="..\..\runtime\ProxyErrorListener.cpp" />
<ClCompile Include="..\..\runtime\RecognitionException.cpp" />
<ClCompile Include="..\..\runtime\Recognizer.cpp" />
<ClCompile Include="..\..\runtime\RuleContext.cpp" />
<ClCompile Include="..\..\runtime\support\Arrays.cpp" />
<ClCompile Include="..\..\runtime\support\CPPUtils.cpp" />
<ClCompile Include="..\..\runtime\support\guid.cpp" />
<ClCompile Include="..\..\runtime\support\Strings.cpp" />
<ClCompile Include="..\..\runtime\Token.cpp" />
<ClCompile Include="..\..\runtime\TokenFactory.cpp" />
<ClCompile Include="..\..\runtime\TokenSource.cpp" />
<ClCompile Include="..\..\runtime\TokenStream.cpp" />
<ClCompile Include="..\..\runtime\TokenStreamRewriter.cpp" />
<ClCompile Include="..\..\runtime\tree\AbstractParseTreeVisitor.cpp" />
<ClCompile Include="..\..\runtime\tree\ErrorNode.cpp" />
<ClCompile Include="..\..\runtime\tree\ErrorNodeImpl.cpp" />
<ClCompile Include="..\..\runtime\tree\ParseTree.cpp" />
<ClCompile Include="..\..\runtime\tree\ParseTreeListener.cpp" />
<ClCompile Include="..\..\runtime\tree\ParseTreeProperty.cpp" />
<ClCompile Include="..\..\runtime\tree\ParseTreeVisitor.cpp" />
<ClCompile Include="..\..\runtime\tree\ParseTreeWalker.cpp" />
<ClCompile Include="..\..\runtime\tree\pattern\Chunk.cpp" />
<ClCompile Include="..\..\runtime\tree\pattern\ParseTreeMatch.cpp" />
<ClCompile Include="..\..\runtime\tree\pattern\ParseTreePattern.cpp" />
<ClCompile Include="..\..\runtime\tree\pattern\ParseTreePatternMatcher.cpp" />
<ClCompile Include="..\..\runtime\tree\pattern\RuleTagToken.cpp" />
<ClCompile Include="..\..\runtime\tree\pattern\TagChunk.cpp" />
<ClCompile Include="..\..\runtime\tree\pattern\TextChunk.cpp" />
<ClCompile Include="..\..\runtime\tree\pattern\TokenTagToken.cpp" />
<ClCompile Include="..\..\runtime\tree\RuleNode.cpp" />
<ClCompile Include="..\..\runtime\tree\SyntaxTree.cpp" />
<ClCompile Include="..\..\runtime\tree\TerminalNode.cpp" />
<ClCompile Include="..\..\runtime\tree\TerminalNodeImpl.cpp" />
<ClCompile Include="..\..\runtime\tree\Tree.cpp" />
<ClCompile Include="..\..\runtime\tree\Trees.cpp" />
<ClCompile Include="..\..\runtime\UnbufferedCharStream.cpp" />
<ClCompile Include="..\..\runtime\UnbufferedTokenStream.cpp" />
<ClCompile Include="..\..\runtime\WritableToken.cpp" />
<ClCompile Include="antlrcpp-Prefix.cpp">
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">Create</PrecompiledHeader>
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Create</PrecompiledHeader>
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">Create</PrecompiledHeader>
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|x64'">Create</PrecompiledHeader>
</ClCompile>
</ItemGroup>
<ItemGroup>
<ClInclude Include="..\antlrcpp\Arrays.h" />
<ClInclude Include="..\antlrcpp\CPPUtils.h" />
<ClInclude Include="..\antlrcpp\StringBuilder.h" />
<ClInclude Include="..\antlrcpp\Strings.h" />
<ClInclude Include="..\antlrcpp\UUID.h" />
<ClInclude Include="..\org\antlr\v4\runtime\ANTLRErrorListener.h" />
<ClInclude Include="..\org\antlr\v4\runtime\ANTLRErrorStrategy.h" />
<ClInclude Include="..\org\antlr\v4\runtime\ANTLRFileStream.h" />
<ClInclude Include="..\org\antlr\v4\runtime\ANTLRInputStream.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\AbstractPredicateTransition.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\ActionTransition.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\ArrayPredictionContext.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\ATN.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\ATNConfig.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\ATNConfigSet.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\ATNDeserializationOptions.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\ATNDeserializer.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\ATNSerializer.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\ATNSimulator.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\ATNState.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\ATNType.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\AtomTransition.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\BasicBlockStartState.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\BasicState.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\BlockEndState.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\BlockStartState.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\DecisionState.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\EmptyPredictionContext.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\EpsilonTransition.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\LexerATNConfig.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\LexerATNSimulator.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\LL1Analyzer.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\LoopEndState.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\NotSetTransition.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\OrderedATNConfigSet.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\ParserATNSimulator.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\PlusBlockStartState.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\PlusLoopbackState.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\PrecedencePredicateTransition.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\PredicateTransition.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\PredictionContext.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\PredictionContextCache.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\PredictionMode.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\RangeTransition.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\RuleStartState.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\RuleStopState.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\RuleTransition.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\SemanticContext.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\SetTransition.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\SingletonPredictionContext.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\StarBlockStartState.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\StarLoopbackState.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\StarLoopEntryState.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\TokensStartState.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\Transition.h" />
<ClInclude Include="..\org\antlr\v4\runtime\atn\WildcardTransition.h" />
<ClInclude Include="..\org\antlr\v4\runtime\BailErrorStrategy.h" />
<ClInclude Include="..\org\antlr\v4\runtime\BaseErrorListener.h" />
<ClInclude Include="..\org\antlr\v4\runtime\BufferedTokenStream.h" />
<ClInclude Include="..\org\antlr\v4\runtime\CharStream.h" />
<ClInclude Include="..\org\antlr\v4\runtime\CommonToken.h" />
<ClInclude Include="..\org\antlr\v4\runtime\CommonTokenFactory.h" />
<ClInclude Include="..\org\antlr\v4\runtime\CommonTokenStream.h" />
<ClInclude Include="..\org\antlr\v4\runtime\ConsoleErrorListener.h" />
<ClInclude Include="..\org\antlr\v4\runtime\DefaultErrorStrategy.h" />
<ClInclude Include="..\org\antlr\v4\runtime\dfa\DFA.h" />
<ClInclude Include="..\org\antlr\v4\runtime\dfa\DFASerializer.h" />
<ClInclude Include="..\org\antlr\v4\runtime\dfa\DFAState.h" />
<ClInclude Include="..\org\antlr\v4\runtime\dfa\LexerDFASerializer.h" />
<ClInclude Include="..\org\antlr\v4\runtime\DiagnosticErrorListener.h" />
<ClInclude Include="..\org\antlr\v4\runtime\Exceptions.h" />
<ClInclude Include="..\org\antlr\v4\runtime\FailedPredicateException.h" />
<ClInclude Include="..\org\antlr\v4\runtime\InputMismatchException.h" />
<ClInclude Include="..\org\antlr\v4\runtime\InterpreterRuleContext.h" />
<ClInclude Include="..\org\antlr\v4\runtime\IntStream.h" />
<ClInclude Include="..\org\antlr\v4\runtime\Lexer.h" />
<ClInclude Include="..\org\antlr\v4\runtime\LexerInterpreter.h" />
<ClInclude Include="..\org\antlr\v4\runtime\LexerNoViableAltException.h" />
<ClInclude Include="..\org\antlr\v4\runtime\ListTokenSource.h" />
<ClInclude Include="..\org\antlr\v4\runtime\misc\AbstractEqualityComparator.h" />
<ClInclude Include="..\org\antlr\v4\runtime\misc\Array2DHashSet.h" />
<ClInclude Include="..\org\antlr\v4\runtime\misc\DoubleKeyMap.h" />
<ClInclude Include="..\org\antlr\v4\runtime\misc\EqualityComparator.h" />
<ClInclude Include="..\org\antlr\v4\runtime\misc\GraphicsSupport.h" />
<ClInclude Include="..\org\antlr\v4\runtime\misc\Interval.h" />
<ClInclude Include="..\org\antlr\v4\runtime\misc\IntervalSet.h" />
<ClInclude Include="..\org\antlr\v4\runtime\misc\IntSet.h" />
<ClInclude Include="..\org\antlr\v4\runtime\misc\LogManager.h" />
<ClInclude Include="..\org\antlr\v4\runtime\misc\MultiMap.h" />
<ClInclude Include="..\org\antlr\v4\runtime\misc\MurmurHash.h" />
<ClInclude Include="..\org\antlr\v4\runtime\misc\NotNull.h" />
<ClInclude Include="..\org\antlr\v4\runtime\misc\ObjectEqualityComparator.h" />
<ClInclude Include="..\org\antlr\v4\runtime\misc\OrderedHashSet.h" />
<ClInclude Include="..\org\antlr\v4\runtime\misc\ParseCancellationException.h" />
<ClInclude Include="..\org\antlr\v4\runtime\misc\TestRig.h" />
<ClInclude Include="..\org\antlr\v4\runtime\misc\Utils.h" />
<ClInclude Include="..\org\antlr\v4\runtime\NoViableAltException.h" />
<ClInclude Include="..\org\antlr\v4\runtime\Parser.h" />
<ClInclude Include="..\org\antlr\v4\runtime\ParserInterpreter.h" />
<ClInclude Include="..\org\antlr\v4\runtime\ParserRuleContext.h" />
<ClInclude Include="..\org\antlr\v4\runtime\ProxyErrorListener.h" />
<ClInclude Include="..\org\antlr\v4\runtime\RecognitionException.h" />
<ClInclude Include="..\org\antlr\v4\runtime\Recognizer.h" />
<ClInclude Include="..\org\antlr\v4\runtime\RuleContext.h" />
<ClInclude Include="..\org\antlr\v4\runtime\Token.h" />
<ClInclude Include="..\org\antlr\v4\runtime\TokenFactory.h" />
<ClInclude Include="..\org\antlr\v4\runtime\TokenSource.h" />
<ClInclude Include="..\org\antlr\v4\runtime\TokenStream.h" />
<ClInclude Include="..\org\antlr\v4\runtime\TokenStreamRewriter.h" />
<ClInclude Include="..\org\antlr\v4\runtime\tree\AbstractParseTreeVisitor.h" />
<ClInclude Include="..\org\antlr\v4\runtime\tree\ErrorNode.h" />
<ClInclude Include="..\org\antlr\v4\runtime\tree\ErrorNodeImpl.h" />
<ClInclude Include="..\org\antlr\v4\runtime\tree\ParseTree.h" />
<ClInclude Include="..\org\antlr\v4\runtime\tree\ParseTreeListener.h" />
<ClInclude Include="..\org\antlr\v4\runtime\tree\ParseTreeProperty.h" />
<ClInclude Include="..\org\antlr\v4\runtime\tree\ParseTreeVisitor.h" />
<ClInclude Include="..\org\antlr\v4\runtime\tree\ParseTreeWalker.h" />
<ClInclude Include="..\org\antlr\v4\runtime\tree\pattern\Chunk.h" />
<ClInclude Include="..\org\antlr\v4\runtime\tree\pattern\ParseTreeMatch.h" />
<ClInclude Include="..\org\antlr\v4\runtime\tree\pattern\ParseTreePattern.h" />
<ClInclude Include="..\org\antlr\v4\runtime\tree\pattern\ParseTreePatternMatcher.h" />
<ClInclude Include="..\org\antlr\v4\runtime\tree\pattern\RuleTagToken.h" />
<ClInclude Include="..\org\antlr\v4\runtime\tree\pattern\TagChunk.h" />
<ClInclude Include="..\org\antlr\v4\runtime\tree\pattern\TextChunk.h" />
<ClInclude Include="..\org\antlr\v4\runtime\tree\pattern\TokenTagToken.h" />
<ClInclude Include="..\org\antlr\v4\runtime\tree\RuleNode.h" />
<ClInclude Include="..\org\antlr\v4\runtime\tree\SyntaxTree.h" />
<ClInclude Include="..\org\antlr\v4\runtime\tree\TerminalNode.h" />
<ClInclude Include="..\org\antlr\v4\runtime\tree\TerminalNodeImpl.h" />
<ClInclude Include="..\org\antlr\v4\runtime\tree\Tree.h" />
<ClInclude Include="..\org\antlr\v4\runtime\tree\Trees.h" />
<ClInclude Include="..\org\antlr\v4\runtime\tree\xpath\XPath.h" />
<ClInclude Include="..\org\antlr\v4\runtime\tree\xpath\XPathElement.h" />
<ClInclude Include="..\org\antlr\v4\runtime\tree\xpath\XPathLexer.h" />
<ClInclude Include="..\org\antlr\v4\runtime\tree\xpath\XPathLexerErrorListener.h" />
<ClInclude Include="..\org\antlr\v4\runtime\tree\xpath\XPathRuleAnywhereElement.h" />
<ClInclude Include="..\org\antlr\v4\runtime\tree\xpath\XPathRuleElement.h" />
<ClInclude Include="..\org\antlr\v4\runtime\tree\xpath\XPathTokenAnywhereElement.h" />
<ClInclude Include="..\org\antlr\v4\runtime\tree\xpath\XPathTokenElement.h" />
<ClInclude Include="..\org\antlr\v4\runtime\tree\xpath\XPathWildcardAnywhereElement.h" />
<ClInclude Include="..\org\antlr\v4\runtime\tree\xpath\XPathWildcardElement.h" />
<ClInclude Include="..\org\antlr\v4\runtime\UnbufferedCharStream.h" />
<ClInclude Include="..\org\antlr\v4\runtime\UnbufferedTokenStream.h" />
<ClInclude Include="..\org\antlr\v4\runtime\WritableToken.h" />
</ItemGroup>
<ItemGroup>
<None Include="..\org\antlr\v4\runtime\atn\Makefile" />
<ClInclude Include="..\..\runtime\antlrcpp-Prefix.h" />
<ClInclude Include="..\..\runtime\ANTLRErrorListener.h" />
<ClInclude Include="..\..\runtime\ANTLRErrorStrategy.h" />
<ClInclude Include="..\..\runtime\ANTLRFileStream.h" />
<ClInclude Include="..\..\runtime\ANTLRInputStream.h" />
<ClInclude Include="..\..\runtime\atn\AbstractPredicateTransition.h" />
<ClInclude Include="..\..\runtime\atn\ActionTransition.h" />
<ClInclude Include="..\..\runtime\atn\ArrayPredictionContext.h" />
<ClInclude Include="..\..\runtime\atn\ATN.h" />
<ClInclude Include="..\..\runtime\atn\ATNConfig.h" />
<ClInclude Include="..\..\runtime\atn\ATNConfigSet.h" />
<ClInclude Include="..\..\runtime\atn\ATNDeserializationOptions.h" />
<ClInclude Include="..\..\runtime\atn\ATNDeserializer.h" />
<ClInclude Include="..\..\runtime\atn\ATNSerializer.h" />
<ClInclude Include="..\..\runtime\atn\ATNSimulator.h" />
<ClInclude Include="..\..\runtime\atn\ATNState.h" />
<ClInclude Include="..\..\runtime\atn\ATNType.h" />
<ClInclude Include="..\..\runtime\atn\AtomTransition.h" />
<ClInclude Include="..\..\runtime\atn\BasicBlockStartState.h" />
<ClInclude Include="..\..\runtime\atn\BasicState.h" />
<ClInclude Include="..\..\runtime\atn\BlockEndState.h" />
<ClInclude Include="..\..\runtime\atn\BlockStartState.h" />
<ClInclude Include="..\..\runtime\atn\ConfigLookup.h" />
<ClInclude Include="..\..\runtime\atn\DecisionState.h" />
<ClInclude Include="..\..\runtime\atn\EmptyPredictionContext.h" />
<ClInclude Include="..\..\runtime\atn\EpsilonTransition.h" />
<ClInclude Include="..\..\runtime\atn\LexerATNConfig.h" />
<ClInclude Include="..\..\runtime\atn\LexerATNSimulator.h" />
<ClInclude Include="..\..\runtime\atn\LL1Analyzer.h" />
<ClInclude Include="..\..\runtime\atn\LoopEndState.h" />
<ClInclude Include="..\..\runtime\atn\NotSetTransition.h" />
<ClInclude Include="..\..\runtime\atn\OrderedATNConfigSet.h" />
<ClInclude Include="..\..\runtime\atn\ParserATNSimulator.h" />
<ClInclude Include="..\..\runtime\atn\PlusBlockStartState.h" />
<ClInclude Include="..\..\runtime\atn\PlusLoopbackState.h" />
<ClInclude Include="..\..\runtime\atn\PrecedencePredicateTransition.h" />
<ClInclude Include="..\..\runtime\atn\PredicateTransition.h" />
<ClInclude Include="..\..\runtime\atn\PredictionContext.h" />
<ClInclude Include="..\..\runtime\atn\PredictionMode.h" />
<ClInclude Include="..\..\runtime\atn\RangeTransition.h" />
<ClInclude Include="..\..\runtime\atn\RuleStartState.h" />
<ClInclude Include="..\..\runtime\atn\RuleStopState.h" />
<ClInclude Include="..\..\runtime\atn\RuleTransition.h" />
<ClInclude Include="..\..\runtime\atn\SemanticContext.h" />
<ClInclude Include="..\..\runtime\atn\SetTransition.h" />
<ClInclude Include="..\..\runtime\atn\SingletonPredictionContext.h" />
<ClInclude Include="..\..\runtime\atn\StarBlockStartState.h" />
<ClInclude Include="..\..\runtime\atn\StarLoopbackState.h" />
<ClInclude Include="..\..\runtime\atn\StarLoopEntryState.h" />
<ClInclude Include="..\..\runtime\atn\TokensStartState.h" />
<ClInclude Include="..\..\runtime\atn\Transition.h" />
<ClInclude Include="..\..\runtime\atn\WildcardTransition.h" />
<ClInclude Include="..\..\runtime\BailErrorStrategy.h" />
<ClInclude Include="..\..\runtime\BaseErrorListener.h" />
<ClInclude Include="..\..\runtime\BufferedTokenStream.h" />
<ClInclude Include="..\..\runtime\CharStream.h" />
<ClInclude Include="..\..\runtime\CommonToken.h" />
<ClInclude Include="..\..\runtime\CommonTokenFactory.h" />
<ClInclude Include="..\..\runtime\CommonTokenStream.h" />
<ClInclude Include="..\..\runtime\ConsoleErrorListener.h" />
<ClInclude Include="..\..\runtime\DefaultErrorStrategy.h" />
<ClInclude Include="..\..\runtime\dfa\DFA.h" />
<ClInclude Include="..\..\runtime\dfa\DFASerializer.h" />
<ClInclude Include="..\..\runtime\dfa\DFAState.h" />
<ClInclude Include="..\..\runtime\dfa\LexerDFASerializer.h" />
<ClInclude Include="..\..\runtime\DiagnosticErrorListener.h" />
<ClInclude Include="..\..\runtime\Exceptions.h" />
<ClInclude Include="..\..\runtime\FailedPredicateException.h" />
<ClInclude Include="..\..\runtime\InputMismatchException.h" />
<ClInclude Include="..\..\runtime\InterpreterRuleContext.h" />
<ClInclude Include="..\..\runtime\IntStream.h" />
<ClInclude Include="..\..\runtime\IRecognizer.h" />
<ClInclude Include="..\..\runtime\Lexer.h" />
<ClInclude Include="..\..\runtime\LexerInterpreter.h" />
<ClInclude Include="..\..\runtime\LexerNoViableAltException.h" />
<ClInclude Include="..\..\runtime\ListTokenSource.h" />
<ClInclude Include="..\..\runtime\misc\Interval.h" />
<ClInclude Include="..\..\runtime\misc\IntervalSet.h" />
<ClInclude Include="..\..\runtime\misc\MurmurHash.h" />
<ClInclude Include="..\..\runtime\misc\TestRig.h" />
<ClInclude Include="..\..\runtime\NoViableAltException.h" />
<ClInclude Include="..\..\runtime\Parser.h" />
<ClInclude Include="..\..\runtime\ParserInterpreter.h" />
<ClInclude Include="..\..\runtime\ParserRuleContext.h" />
<ClInclude Include="..\..\runtime\ProxyErrorListener.h" />
<ClInclude Include="..\..\runtime\RecognitionException.h" />
<ClInclude Include="..\..\runtime\Recognizer.h" />
<ClInclude Include="..\..\runtime\RuleContext.h" />
<ClInclude Include="..\..\runtime\support\Arrays.h" />
<ClInclude Include="..\..\runtime\support\BitSet.h" />
<ClInclude Include="..\..\runtime\support\CPPUtils.h" />
<ClInclude Include="..\..\runtime\support\Declarations.h" />
<ClInclude Include="..\..\runtime\support\guid.h" />
<ClInclude Include="..\..\runtime\support\Strings.h" />
<ClInclude Include="..\..\runtime\Token.h" />
<ClInclude Include="..\..\runtime\TokenFactory.h" />
<ClInclude Include="..\..\runtime\TokenSource.h" />
<ClInclude Include="..\..\runtime\TokenStream.h" />
<ClInclude Include="..\..\runtime\TokenStreamRewriter.h" />
<ClInclude Include="..\..\runtime\tree\AbstractParseTreeVisitor.h" />
<ClInclude Include="..\..\runtime\tree\ErrorNode.h" />
<ClInclude Include="..\..\runtime\tree\ErrorNodeImpl.h" />
<ClInclude Include="..\..\runtime\tree\ParseTree.h" />
<ClInclude Include="..\..\runtime\tree\ParseTreeListener.h" />
<ClInclude Include="..\..\runtime\tree\ParseTreeProperty.h" />
<ClInclude Include="..\..\runtime\tree\ParseTreeVisitor.h" />
<ClInclude Include="..\..\runtime\tree\ParseTreeWalker.h" />
<ClInclude Include="..\..\runtime\tree\pattern\Chunk.h" />
<ClInclude Include="..\..\runtime\tree\pattern\ParseTreeMatch.h" />
<ClInclude Include="..\..\runtime\tree\pattern\ParseTreePattern.h" />
<ClInclude Include="..\..\runtime\tree\pattern\ParseTreePatternMatcher.h" />
<ClInclude Include="..\..\runtime\tree\pattern\RuleTagToken.h" />
<ClInclude Include="..\..\runtime\tree\pattern\TagChunk.h" />
<ClInclude Include="..\..\runtime\tree\pattern\TextChunk.h" />
<ClInclude Include="..\..\runtime\tree\pattern\TokenTagToken.h" />
<ClInclude Include="..\..\runtime\tree\RuleNode.h" />
<ClInclude Include="..\..\runtime\tree\SyntaxTree.h" />
<ClInclude Include="..\..\runtime\tree\TerminalNode.h" />
<ClInclude Include="..\..\runtime\tree\TerminalNodeImpl.h" />
<ClInclude Include="..\..\runtime\tree\Tree.h" />
<ClInclude Include="..\..\runtime\tree\Trees.h" />
<ClInclude Include="..\..\runtime\tree\xpath\XPathLexer.h" />
<ClInclude Include="..\..\runtime\UnbufferedCharStream.h" />
<ClInclude Include="..\..\runtime\UnbufferedTokenStream.h" />
<ClInclude Include="..\..\runtime\WritableToken.h" />
</ItemGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,29 @@
/*
* [The "BSD license"]
* Copyright (c) 2016 Mike Lischke
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
* 3. The name of the author may not be used to endorse or promote products
* derived from this software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
* IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
* OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
* IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
* INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
* NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/

View File

@ -0,0 +1,10 @@
:: Created 2016, Mike Lischke (public domain)
:: This script is used to generate source files from the test grammars in the same folder. The generated files are placed
:: into a subfolder "generated" which the demo project uses to compile a demo binary.
set LOCATION=antlr-4.1.1-dev-complete.jar
::java -jar %LOCATION% -Dlanguage=Cpp -listener -visitor -o generated/ -package antlrcpptest TLexer.g4 TParser.g4
::java -jar %LOCATION% -Dlanguage=Cpp -listener -visitor -o generated/ -package antlrcpptest -XdbgST TLexer.g4 TParser.g4
java -jar %LOCATION% -Dlanguage=Java -listener -visitor -o generated/ -package antlrcpptest TLexer.g4 TParser.g4

View File

@ -49,7 +49,7 @@ void ANTLRFileStream::load(const std::string &fileName, const std::string &encod
enum Encoding { ANSI, UTF8, UTF16LE } encodingType = ANSI;
#ifdef _WIN32
std::ifstream stream(antlrcpp::s2ws(filename).c_str(), std::ios::binary);
std::ifstream stream(antlrcpp::s2ws(fileName).c_str(), std::ios::binary);
#else
std::ifstream stream(_fileName.c_str(), std::ifstream::binary);
#endif

View File

@ -48,11 +48,16 @@ void BailErrorStrategy::recover(Parser *recognizer, const RecognitionException &
context = context->getParent().lock();
} while (true);
#if defined(_MSC_FULL_VER) && _MSC_FULL_VER < 190023026
// throw_with_nested is not available before VS 2015.
std::rethrow_exception(exception);
#else
try {
std::rethrow_exception(exception); // Throw the exception to be able to catch and rethrow nested.
} catch (RecognitionException &inner) {
std::throw_with_nested(ParseCancellationException());
}
#endif
}
Token::Ref BailErrorStrategy::recoverInline(Parser *recognizer) {
@ -67,11 +72,15 @@ Token::Ref BailErrorStrategy::recoverInline(Parser *recognizer) {
context = context->getParent().lock();
} while (true);
#if defined(_MSC_FULL_VER) && _MSC_FULL_VER < 190023026
throw e;
#else
try {
throw e;
} catch (InputMismatchException &inner) {
std::throw_with_nested(ParseCancellationException());
}
#endif
}
void BailErrorStrategy::sync(Parser *recognizer) {

View File

@ -32,6 +32,7 @@
#pragma once
#include "IntStream.h"
#include "Interval.h"
namespace org {
namespace antlr {

View File

@ -36,7 +36,7 @@ RuntimeException::RuntimeException(const std::string &msg)
: std::exception(), _message(msg) {
}
const char* RuntimeException::what() const noexcept {
const char* RuntimeException::what() const NOEXCEPT {
return _message.c_str();
}
@ -45,6 +45,6 @@ const char* RuntimeException::what() const noexcept {
IOException::IOException(const std::string &msg) : std::exception(), _message(msg) {
}
const char* IOException::what() const noexcept {
const char* IOException::what() const NOEXCEPT {
return _message.c_str();
}

View File

@ -42,7 +42,7 @@ namespace runtime {
public:
RuntimeException(const std::string &msg = "");
virtual const char* what() const noexcept override;
virtual const char* what() const NOEXCEPT override;
};
class IllegalStateException : public RuntimeException {
@ -84,7 +84,7 @@ namespace runtime {
public:
IOException(const std::string &msg = "");
virtual const char* what() const noexcept override;
virtual const char* what() const NOEXCEPT override;
};
class CancellationException : public IllegalStateException {

View File

@ -507,12 +507,13 @@ misc::IntervalSet Parser::getExpectedTokensWithinCurrentRule() {
return atn.nextTokens(s);
}
int Parser::getRuleIndex(const std::wstring &ruleName) {
const std::map<std::wstring, int> &m = getRuleIndexMap();
if (m.find(ruleName) == m.end()) {
ssize_t Parser::getRuleIndex(const std::wstring &ruleName) {
const std::map<std::wstring, size_t> &m = getRuleIndexMap();
auto iterator = m.find(ruleName);
if (iterator == m.end()) {
return -1;
}
return m.at(ruleName);
return iterator->second;
}
ParserRuleContext::Ref Parser::getRuleContext() {

View File

@ -355,7 +355,7 @@ namespace runtime {
/// <summary>
/// Get a rule's index (i.e., {@code RULE_ruleName} field) or -1 if not found. </summary>
virtual int getRuleIndex(const std::wstring &ruleName);
virtual ssize_t getRuleIndex(const std::wstring &ruleName);
virtual ParserRuleContext::Ref getRuleContext();

View File

@ -40,22 +40,22 @@
using namespace org::antlr::v4::runtime;
std::map<std::vector<std::wstring>, std::map<std::wstring, int>> Recognizer::_tokenTypeMapCache;
std::map<std::vector<std::wstring>, std::map<std::wstring, int>> Recognizer::_ruleIndexMapCache;
std::map<std::vector<std::wstring>, std::map<std::wstring, size_t>> Recognizer::_tokenTypeMapCache;
std::map<std::vector<std::wstring>, std::map<std::wstring, size_t>> Recognizer::_ruleIndexMapCache;
Recognizer::Recognizer() {
InitializeInstanceFields();
_proxListener.addErrorListener(&ConsoleErrorListener::INSTANCE);
}
std::map<std::wstring, int> Recognizer::getTokenTypeMap() {
std::map<std::wstring, size_t> Recognizer::getTokenTypeMap() {
const std::vector<std::wstring>& tokenNames = getTokenNames();
if (tokenNames.empty()) {
throw L"The current recognizer does not provide a list of token names.";
}
std::lock_guard<std::mutex> lck(mtx);
std::map<std::wstring, int> result;
std::map<std::wstring, size_t> result;
auto iterator = _tokenTypeMapCache.find(tokenNames);
if (iterator != _tokenTypeMapCache.end()) {
result = iterator->second;
@ -68,14 +68,14 @@ std::map<std::wstring, int> Recognizer::getTokenTypeMap() {
return result;
}
std::map<std::wstring, int> Recognizer::getRuleIndexMap() {
std::map<std::wstring, size_t> Recognizer::getRuleIndexMap() {
const std::vector<std::wstring>& ruleNames = getRuleNames();
if (ruleNames.empty()) {
throw L"The current recognizer does not provide a list of rule names.";
}
std::lock_guard<std::mutex> lck(mtx);
std::map<std::wstring, int> result;
std::map<std::wstring, size_t> result;
auto iterator = _ruleIndexMapCache.find(ruleNames);
if (iterator != _ruleIndexMapCache.end()) {
result = iterator->second;
@ -86,8 +86,8 @@ std::map<std::wstring, int> Recognizer::getRuleIndexMap() {
return result;
}
int Recognizer::getTokenType(const std::wstring &tokenName) {
const std::map<std::wstring, int> &map = getTokenTypeMap();
size_t Recognizer::getTokenType(const std::wstring &tokenName) {
const std::map<std::wstring, size_t> &map = getTokenTypeMap();
auto iterator = map.find(tokenName);
if (iterator == map.end())
return Token::INVALID_TYPE;

View File

@ -44,8 +44,8 @@ namespace runtime {
Recognizer();
private:
static std::map<std::vector<std::wstring>, std::map<std::wstring, int>> _tokenTypeMapCache;
static std::map<std::vector<std::wstring>, std::map<std::wstring, int>> _ruleIndexMapCache;
static std::map<std::vector<std::wstring>, std::map<std::wstring, size_t>> _tokenTypeMapCache;
static std::map<std::vector<std::wstring>, std::map<std::wstring, size_t>> _ruleIndexMapCache;
ProxyErrorListener _proxListener; // Manages a collection of listeners.
@ -73,16 +73,16 @@ namespace runtime {
/// <p/>
/// Used for XPath and tree pattern compilation.
/// </summary>
virtual std::map<std::wstring, int> getTokenTypeMap();
virtual std::map<std::wstring, size_t> getTokenTypeMap();
/// <summary>
/// Get a map from rule names to rule indexes.
/// <p/>
/// Used for XPath and tree pattern compilation.
/// </summary>
virtual std::map<std::wstring, int> getRuleIndexMap();
virtual std::map<std::wstring, size_t> getRuleIndexMap();
virtual int getTokenType(const std::wstring &tokenName);
virtual size_t getTokenType(const std::wstring &tokenName);
/// <summary>
/// If this recognizer was generated, it will have a serialized ATN

View File

@ -85,7 +85,12 @@ size_t UnbufferedCharStream::fill(size_t n) {
size_t c = nextChar();
add(c);
} catch (IOException &ioe) {
#if defined(_MSC_FULL_VER) && _MSC_FULL_VER < 190023026
// throw_with_nested is not available before VS 2015.
throw ioe;
#else
std::throw_with_nested(RuntimeException());
#endif
}
}

View File

@ -54,11 +54,23 @@
#include <unordered_set>
#include <utility>
#include <vector>
#include <mutex>
#include <exception>
#include <bitset>
// Defines for the Guid class.
// Defines for the Guid class and other platform dependent stuff.
#ifdef _WIN32
#pragma warning (disable: 4250) // Class inherits by dominance.
#define GUID_WINDOWS
#elseif __APPLE__
#ifdef _WIN64
typedef __int64 ssize_t;
#else
typedef int ssize_t;
#endif
#elif __APPLE__
#define GUID_CFUUID
#else
#define GUID_LIBUUID
@ -66,3 +78,23 @@
#include "guid.h"
#include "Declarations.h"
#if !defined(HAS_NOEXCEPT)
#if defined(__clang__)
#if __has_feature(cxx_noexcept)
#define HAS_NOEXCEPT
#endif
#else
#if defined(__GXX_EXPERIMENTAL_CXX0X__) && __GNUC__ * 10 + __GNUC_MINOR__ >= 46 || \
defined(_MSC_FULL_VER) && _MSC_FULL_VER >= 190023026
#define HAS_NOEXCEPT
#endif
#endif
#ifdef HAS_NOEXCEPT
#define NOEXCEPT noexcept
#else
#define NOEXCEPT
#endif
#endif

View File

@ -76,7 +76,7 @@ ATN::~ATN() {
/**
* Required to be defined (even though not used) as we have an explicit move assignment operator.
*/
ATN& ATN::operator = (ATN& other) noexcept {
ATN& ATN::operator = (ATN &other) NOEXCEPT {
states = other.states;
decisionToState = other.decisionToState;
ruleToStartState = other.ruleToStartState;
@ -94,7 +94,7 @@ ATN& ATN::operator = (ATN& other) noexcept {
* Explicit move assignment operator to make this the preferred assignment. With implicit copy/move assignment
* operators it seems the copy operator is preferred causing trouble when releasing the allocated ATNState instances.
*/
ATN& ATN::operator = (ATN&& other) noexcept {
ATN& ATN::operator = (ATN &&other) NOEXCEPT {
states = std::move(other.states);
decisionToState = std::move(other.decisionToState);
ruleToStartState = std::move(other.ruleToStartState);

View File

@ -87,8 +87,8 @@ namespace atn {
std::vector<TokensStartState*> modeToStartState;
ATN& operator = (ATN &other) noexcept;
ATN& operator = (ATN &&other) noexcept;
ATN& operator = (ATN &other) NOEXCEPT;
ATN& operator = (ATN &&other) NOEXCEPT;
/// <summary>
/// Compute the set of valid tokens that can occur starting in state {@code s}.

View File

@ -68,42 +68,50 @@
#include "ATNDeserializer.h"
using namespace org::antlr::v4::runtime;
using namespace org::antlr::v4::runtime::atn;
using namespace antlrcpp;
const size_t ATNDeserializer::SERIALIZED_VERSION;
/**
* This value should never change. Updates following this version are
* reflected as change in the unique ID SERIALIZED_UUID.
*/
Guid ATNDeserializer::BASE_SERIALIZED_UUID("33761B2D-78BB-4A43-8B0B-4F5BEE8AACF3");
Guid ATNDeserializer::ADDED_PRECEDENCE_TRANSITIONS("1DA0C57D-6C06-438A-9B27-10BCB3CE0F61");
Guid ATNDeserializer::ADDED_LEXER_ACTIONS("AADB8D7E-AEEF-4415-AD2B-8204D6CF042E");
std::vector<Guid> ATNDeserializer::SUPPORTED_UUIDS = { BASE_SERIALIZED_UUID, ADDED_PRECEDENCE_TRANSITIONS };
Guid ATNDeserializer::SERIALIZED_UUID = ADDED_PRECEDENCE_TRANSITIONS; //ADDED_LEXER_ACTIONS;
const size_t ATNDeserializer::SERIALIZED_VERSION = 3;
ATNDeserializer::ATNDeserializer(): ATNDeserializer(ATNDeserializationOptions::getDefaultOptions()) {
}
ATNDeserializer::ATNDeserializer(const ATNDeserializationOptions& dso): deserializationOptions(dso) {
// XXX: wery weird, from one moment to the next static initialization stopped working. Find out why.
if (SUPPORTED_UUIDS.empty()) {
BASE_SERIALIZED_UUID = Guid("33761B2D-78BB-4A43-8B0B-4F5BEE8AACF3");
ADDED_PRECEDENCE_TRANSITIONS = Guid("1DA0C57D-6C06-438A-9B27-10BCB3CE0F61");
ADDED_LEXER_ACTIONS = Guid("AADB8D7E-AEEF-4415-AD2B-8204D6CF042E");
SUPPORTED_UUIDS = { BASE_SERIALIZED_UUID, ADDED_PRECEDENCE_TRANSITIONS };
SERIALIZED_UUID = ADDED_PRECEDENCE_TRANSITIONS;
}
}
/**
* This value should never change. Updates following this version are
* reflected as change in the unique ID SERIALIZED_UUID.
*/
Guid ATNDeserializer::ADDED_PRECEDENCE_TRANSITIONS() {
return "1DA0C57D-6C06-438A-9B27-10BCB3CE0F61";
}
Guid ATNDeserializer::ADDED_LEXER_ACTIONS() {
return "AADB8D7E-AEEF-4415-AD2B-8204D6CF042E";
}
Guid ATNDeserializer::SERIALIZED_UUID() {
return ADDED_PRECEDENCE_TRANSITIONS(); //ADDED_LEXER_ACTIONS;
}
Guid ATNDeserializer::BASE_SERIALIZED_UUID() {
return "33761B2D-78BB-4A43-8B0B-4F5BEE8AACF3";
}
std::vector<Guid>& ATNDeserializer::SUPPORTED_UUIDS() {
static std::vector<Guid> singleton = { BASE_SERIALIZED_UUID(), ADDED_PRECEDENCE_TRANSITIONS() };
return singleton;
}
bool ATNDeserializer::isFeatureSupported(const Guid &feature, const Guid &actualUuid) {
auto featureIterator = std::find(SUPPORTED_UUIDS.begin(), SUPPORTED_UUIDS.end(), feature);
if (featureIterator == SUPPORTED_UUIDS.end()) {
auto featureIterator = std::find(SUPPORTED_UUIDS().begin(), SUPPORTED_UUIDS().end(), feature);
if (featureIterator == SUPPORTED_UUIDS().end()) {
return false;
}
auto actualIterator = std::find(SUPPORTED_UUIDS.begin(), SUPPORTED_UUIDS.end(), actualUuid);
if (actualIterator == SUPPORTED_UUIDS.end()) {
auto actualIterator = std::find(SUPPORTED_UUIDS().begin(), SUPPORTED_UUIDS().end(), actualUuid);
if (actualIterator == SUPPORTED_UUIDS().end()) {
return false;
}
@ -112,7 +120,7 @@ bool ATNDeserializer::isFeatureSupported(const Guid &feature, const Guid &actual
ATN ATNDeserializer::deserialize(const std::wstring& input) {
// Don't adjust the first value since that's the version number.
uint16_t data[input.size()];
std::vector<uint16_t> data(input.size());
data[0] = input[0];
for (size_t i = 1; i < input.size(); ++i) {
data[i] = input[i] - 2;
@ -126,17 +134,17 @@ ATN ATNDeserializer::deserialize(const std::wstring& input) {
throw UnsupportedOperationException(reason);
}
Guid uuid = toUUID(data, p);
Guid uuid = toUUID(data.data(), p);
p += 8;
auto uuidIterator = std::find(SUPPORTED_UUIDS.begin(), SUPPORTED_UUIDS.end(), uuid);
if (uuidIterator == SUPPORTED_UUIDS.end()) {
auto uuidIterator = std::find(SUPPORTED_UUIDS().begin(), SUPPORTED_UUIDS().end(), uuid);
if (uuidIterator == SUPPORTED_UUIDS().end()) {
std::string reason = "Could not deserialize ATN with UUID " + uuid.toString() + " (expected " +
SERIALIZED_UUID.toString() + " or a legacy UUID).";
SERIALIZED_UUID().toString() + " or a legacy UUID).";
throw UnsupportedOperationException(reason);
}
bool supportsPrecedencePredicates = isFeatureSupported(ADDED_PRECEDENCE_TRANSITIONS, uuid);
bool supportsPrecedencePredicates = isFeatureSupported(ADDED_PRECEDENCE_TRANSITIONS(), uuid);
ATNType grammarType = (ATNType)data[p++];
size_t maxTokenType = data[p++];

View File

@ -41,10 +41,11 @@ namespace atn {
class ATNDeserializer {
public:
static const size_t SERIALIZED_VERSION = 3;
static const size_t SERIALIZED_VERSION;
/// This is the current serialized UUID.
static Guid SERIALIZED_UUID;
// ml: defined as function to avoid the “static initialization order fiasco”.
static Guid SERIALIZED_UUID();
ATNDeserializer();
ATNDeserializer(const ATNDeserializationOptions& dso);
@ -78,26 +79,24 @@ namespace atn {
private:
/// This is the earliest supported serialized UUID.
static Guid BASE_SERIALIZED_UUID;
static Guid BASE_SERIALIZED_UUID();
/// This UUID indicates an extension of <seealso cref="BASE_SERIALIZED_UUID"/> for the
/// addition of precedence predicates.
static Guid ADDED_PRECEDENCE_TRANSITIONS;
static Guid ADDED_PRECEDENCE_TRANSITIONS();
/**
* This UUID indicates an extension of ADDED_PRECEDENCE_TRANSITIONS
* for the addition of lexer actions encoded as a sequence of
* LexerAction instances.
*/
static Guid ADDED_LEXER_ACTIONS;
static Guid ADDED_LEXER_ACTIONS();
/// This list contains all of the currently supported UUIDs, ordered by when
/// the feature first appeared in this branch.
static std::vector<Guid> SUPPORTED_UUIDS;
static std::vector<Guid>& SUPPORTED_UUIDS();
ATNDeserializationOptions deserializationOptions;
static std::vector<Guid> supportedUUIDsInitializer();
};
} // namespace atn

View File

@ -71,7 +71,7 @@ ATNSerializer::ATNSerializer(ATN *atn, const std::vector<std::wstring> &tokenNam
std::vector<size_t> ATNSerializer::serialize() {
std::vector<size_t> data;
data.push_back(ATNDeserializer::SERIALIZED_VERSION);
serializeUUID(data, ATNDeserializer::SERIALIZED_UUID);
serializeUUID(data, ATNDeserializer::SERIALIZED_UUID());
// convert grammar type to ATN const to avoid dependence on ANTLRParser
data.push_back((size_t)atn->grammarType);
@ -129,7 +129,7 @@ std::vector<size_t> ATNSerializer::serialize() {
SetTransition *st = static_cast<SetTransition *>(t);
if (setIndices.find(st->set) != setIndices.end()) {
sets.push_back(st->set);
setIndices.insert({ st->set, sets.size() - 1 });
setIndices.insert({ st->set, (int)sets.size() - 1 });
}
}
}
@ -324,7 +324,7 @@ std::wstring ATNSerializer::decode(const std::wstring &inpdata) {
if (inpdata.size() < 10)
throw IllegalArgumentException("Not enough data to decode");
uint16_t data[inpdata.size()];
std::vector<uint16_t> data(inpdata.size());
data[0] = inpdata[0];
// Don't adjust the first value since that's the version number.
@ -341,11 +341,11 @@ std::wstring ATNSerializer::decode(const std::wstring &inpdata) {
throw UnsupportedOperationException("ATN Serializer" + reason);
}
Guid uuid = ATNDeserializer::toUUID(data, p);
Guid uuid = ATNDeserializer::toUUID(data.data(), p);
p += 8;
if (uuid != ATNDeserializer::SERIALIZED_UUID) {
if (uuid != ATNDeserializer::SERIALIZED_UUID()) {
std::string reason = "Could not deserialize ATN with UUID " + uuid.toString() + " (expected " +
ATNDeserializer::SERIALIZED_UUID.toString() + ").";
ATNDeserializer::SERIALIZED_UUID().toString() + ").";
throw UnsupportedOperationException("ATN Serializer" + reason);
}
@ -529,8 +529,8 @@ std::wstring ATNSerializer::getTokenName(ssize_t t) {
std::wstring ATNSerializer::getSerializedAsString(ATN *atn) {
std::vector<size_t> data = getSerialized(atn);
std::wstring result;
result.resize(data.size());
std::copy(data.begin(), data.end(), result.begin());
for (size_t entry : data)
result.push_back((wchar_t)entry);
return result;
}

View File

@ -37,6 +37,7 @@
#include "ATNSimulator.h"
using namespace org::antlr::v4::runtime;
using namespace org::antlr::v4::runtime::dfa;
using namespace org::antlr::v4::runtime::atn;

View File

@ -39,8 +39,8 @@
using namespace org::antlr::v4::runtime::atn;
using namespace antlrcpp;
const int ATNState::INITIAL_NUM_TRANSITIONS;
const int ATNState::INVALID_STATE_NUMBER;
const int ATNState::INITIAL_NUM_TRANSITIONS = 4;
const int ATNState::INVALID_STATE_NUMBER = -1;
ATNState::~ATNState() {
for (auto transition : transitions) {
@ -48,9 +48,9 @@ ATNState::~ATNState() {
}
};
const std::vector<std::wstring> ATNState::serializationNames = {L"INVALID", L"BASIC", L"RULE_START", L"BLOCK_START",
const std::vector<std::wstring> ATNState::serializationNames = { L"INVALID", L"BASIC", L"RULE_START", L"BLOCK_START",
L"PLUS_BLOCK_START", L"STAR_BLOCK_START", L"TOKEN_START", L"RULE_STOP",
L"BLOCK_END", L"STAR_LOOP_BACK", L"STAR_LOOP_ENTRY", L"PLUS_LOOP_BACK", L"LOOP_END"};
L"BLOCK_END", L"STAR_LOOP_BACK", L"STAR_LOOP_ENTRY", L"PLUS_LOOP_BACK", L"LOOP_END" };
size_t ATNState::hashCode() {
return (size_t)stateNumber;

View File

@ -103,8 +103,8 @@ namespace atn {
public:
virtual ~ATNState();
static const int INITIAL_NUM_TRANSITIONS = 4;
static const int INVALID_STATE_NUMBER = -1;
static const int INITIAL_NUM_TRANSITIONS;
static const int INVALID_STATE_NUMBER;
enum {
ATN_INVALID_TYPE = 0,

View File

@ -46,12 +46,12 @@ namespace atn {
/// Capture lexer action we traverse.
int lexerActionIndex = -1;
LexerATNConfig(ATNState *state, int alt, PredictionContext::Ref context);
LexerATNConfig(ATNState *state, int alt, PredictionContext::Ref context, int actionIndex);
explicit LexerATNConfig(ATNState *state, int alt, PredictionContext::Ref context);
explicit LexerATNConfig(ATNState *state, int alt, PredictionContext::Ref context, int actionIndex);
LexerATNConfig(LexerATNConfig::Ref c, ATNState *state);
LexerATNConfig(LexerATNConfig::Ref c, ATNState *state, int actionIndex);
LexerATNConfig(LexerATNConfig::Ref c, ATNState *state, PredictionContext::Ref context);
explicit LexerATNConfig(LexerATNConfig::Ref c, ATNState *state);
explicit LexerATNConfig(LexerATNConfig::Ref c, ATNState *state, int actionIndex);
explicit LexerATNConfig(LexerATNConfig::Ref c, ATNState *state, PredictionContext::Ref context);
bool hasPassedThroughNonGreedyDecision();

View File

@ -315,7 +315,7 @@ atn::ATNState *LexerATNSimulator::getReachableTarget(Transition *trans, ssize_t
}
std::shared_ptr<ATNConfigSet> LexerATNSimulator::computeStartState(CharStream *input, ATNState *p) {
std::shared_ptr<EmptyPredictionContext> initialContext = PredictionContext::EMPTY; // ml: the purpose of this assignment is unclear
std::shared_ptr<PredictionContext> initialContext = PredictionContext::EMPTY; // ml: the purpose of this assignment is unclear
std::shared_ptr<ATNConfigSet> configs = std::make_shared<OrderedATNConfigSet>();
for (size_t i = 0; i < p->getNumberOfTransitions(); i++) {
ATNState *target = p->transition(i)->target;

View File

@ -33,6 +33,7 @@
#include "ATNState.h"
#include "IntervalSet.h"
using namespace org::antlr::v4::runtime;
using namespace org::antlr::v4::runtime::atn;
NotSetTransition::NotSetTransition(ATNState *target, const misc::IntervalSet &set) : SetTransition(target, set) {

View File

@ -40,13 +40,14 @@
#include "PredictionContext.h"
using namespace org::antlr::v4::runtime;
using namespace org::antlr::v4::runtime::misc;
using namespace org::antlr::v4::runtime::atn;
using namespace antlrcpp;
int PredictionContext::globalNodeCount = 0;
const std::shared_ptr<EmptyPredictionContext> PredictionContext::EMPTY = std::make_shared<EmptyPredictionContext>();
const PredictionContext::Ref PredictionContext::EMPTY = std::make_shared<EmptyPredictionContext>();
const int PredictionContext::EMPTY_RETURN_STATE;
const int PredictionContext::INITIAL_HASH;
@ -580,7 +581,7 @@ std::vector<std::wstring> PredictionContext::toStrings(Recognizer *recognizer, P
size_t index = 0;
if (p->size() > 0) {
size_t bits = 1;
while ((1 << bits) < p->size()) {
while ((1ULL << bits) < p->size()) {
bits++;
}

View File

@ -53,7 +53,7 @@ namespace atn {
/// Represents $ in local context prediction, which means wildcard.
/// *+x = *.
static const std::shared_ptr<EmptyPredictionContext> EMPTY;
static const Ref EMPTY;
/// Represents $ in an array in full context mode, when $
/// doesn't mean wildcard: $ + x = [$,x]. Here,

View File

@ -34,6 +34,7 @@
#include "SemanticContext.h"
using namespace org::antlr::v4::runtime;
using namespace org::antlr::v4::runtime::atn;
using namespace antlrcpp;

View File

@ -44,7 +44,7 @@ SingletonPredictionContext::SingletonPredictionContext(std::weak_ptr<PredictionC
SingletonPredictionContext::Ref SingletonPredictionContext::create(std::weak_ptr<PredictionContext> parent, int returnState) {
if (returnState == EMPTY_RETURN_STATE && parent.expired()) {
// someone can pass in the bits of an array ctx that mean $
return EMPTY;
return std::dynamic_pointer_cast<SingletonPredictionContext>(EMPTY);
}
return std::make_shared<SingletonPredictionContext>(parent, returnState);
}

View File

@ -35,6 +35,7 @@
#include "DFA.h"
using namespace org::antlr::v4::runtime;
using namespace org::antlr::v4::runtime::dfa;
DFA::DFA(atn::DecisionState *atnStartState) : DFA(atnStartState, 0) {

View File

@ -35,6 +35,7 @@
#include "IntervalSet.h"
using namespace org::antlr::v4::runtime;
using namespace org::antlr::v4::runtime::misc;
IntervalSet const IntervalSet::COMPLETE_CHAR_SET = IntervalSet::of(0, Lexer::MAX_CHAR_VALUE);

View File

@ -45,8 +45,8 @@ namespace antlrcpp {
return str;
}
std::map<std::wstring, int> toMap(const std::vector<std::wstring> &keys) {
std::map<std::wstring, int> result;
std::map<std::wstring, size_t> toMap(const std::vector<std::wstring> &keys) {
std::map<std::wstring, size_t> result;
for (size_t i = 0; i < keys.size(); ++i) {
result.insert({ keys[i], i });
}
@ -59,7 +59,7 @@ namespace antlrcpp {
switch (c) {
case L' ':
if (escapeSpaces) {
result += '0xB7';
result += (wchar_t)'0xB7';
break;
} else {
// fall through

View File

@ -33,7 +33,7 @@
namespace antlrcpp {
std::wstring join(std::vector<std::wstring> strings, const std::wstring &separator);
std::map<std::wstring, int> toMap(const std::vector<std::wstring> &keys);
std::map<std::wstring, size_t> toMap(const std::vector<std::wstring> &keys);
std::wstring escapeWhitespace(std::wstring str, bool escapeSpaces);
std::wstring toHexString(const int t);
std::wstring arrayToString(const std::vector<std::wstring> &data);

View File

@ -116,7 +116,12 @@ ParseTreePattern ParseTreePatternMatcher::compile(const std::wstring &pattern, i
ParserRuleContext::Ref context = parserInterp.parse(patternRuleIndex);
return ParseTreePattern(this, pattern, patternRuleIndex, context);
} catch (std::exception &e) {
#if defined(_MSC_FULL_VER) && _MSC_FULL_VER < 190023026
// throw_with_nested is not available before VS 2015.
throw e;
#else
std::throw_with_nested("Cannot invoke start rule");
#endif
}
}
@ -244,15 +249,15 @@ std::vector<Token::Ref> ParseTreePatternMatcher::tokenize(const std::wstring &pa
TagChunk &tagChunk = (TagChunk&)chunk;
// add special rule token or conjure up new token from name
if (isupper(tagChunk.getTag()[0])) {
int ttype = _parser->getTokenType(tagChunk.getTag());
size_t ttype = _parser->getTokenType(tagChunk.getTag());
if (ttype == Token::INVALID_TYPE) {
throw IllegalArgumentException("Unknown token " + antlrcpp::ws2s(tagChunk.getTag()) +
" in pattern: " + antlrcpp::ws2s(pattern));
}
std::shared_ptr<TokenTagToken> t = std::make_shared<TokenTagToken>(tagChunk.getTag(), ttype, tagChunk.getLabel());
std::shared_ptr<TokenTagToken> t = std::make_shared<TokenTagToken>(tagChunk.getTag(), (int)ttype, tagChunk.getLabel());
tokens.push_back(t);
} else if (islower(tagChunk.getTag()[0])) {
int ruleIndex = _parser->getRuleIndex(tagChunk.getTag());
ssize_t ruleIndex = _parser->getRuleIndex(tagChunk.getTag());
if (ruleIndex == -1) {
throw IllegalArgumentException(std::string("Unknown rule ") + antlrcpp::ws2s(tagChunk.getTag()) + " in pattern: " + antlrcpp::ws2s(pattern));
}