diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index 33082b8bc7..a4d0ca918a 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -40,7 +40,7 @@ jobs:
eigen: NO
- profile: macos-eigen-coverage-unity-xcode
- os: macOS-11
+ os: macOS-12
config: Coverage
unity: YES
generator: Xcode
@@ -50,7 +50,7 @@ jobs:
eigen: YES
- profile: macos-nometa-standard-makefile
- os: macOS-11
+ os: macOS-12
config: Standard
unity: NO
generator: Unix Makefiles
@@ -361,7 +361,7 @@ jobs:
if: "!contains(github.event.head_commit.message, '[skip ci]') && !contains(github.event.head_commit.message, '[ci skip]')"
strategy:
matrix:
- os: [ubuntu-20.04, windows-2019, macOS-11]
+ os: [ubuntu-20.04, windows-2019, macOS-12]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v1
@@ -472,14 +472,6 @@ jobs:
sudo apt-get update
sudo apt-get install build-essential ninja-build bison flex
- - name: Build Host Interrogate
- shell: bash
- run: |
- mkdir -p host-build
- cmake -S . -B host-build -DBUILD_DIRECT=OFF -DBUILD_PANDA=OFF -DBUILD_PANDATOOL=OFF -DBUILD_CONTRIB=OFF -DBUILD_DTOOL=ON -DBUILD_MODELS=OFF -DBUILD_SHARED_LIBS=OFF -DINTERROGATE_PYTHON_INTERFACE=OFF
- cmake --build host-build --config Standard --parallel 4
- echo host-build/bin >> $GITHUB_PATH
-
- name: Setup emsdk
uses: mymindstorm/setup-emsdk@v14
with:
diff --git a/BACKERS.md b/BACKERS.md
index d1a9dd8727..a3eb53177b 100644
--- a/BACKERS.md
+++ b/BACKERS.md
@@ -4,10 +4,11 @@ This is a list of all the people who are contributing financially to Panda3D. I
## Bronze Sponsors
-[
](https://changecrab.com/) 
+[
](https://route4me.com/)
* [Daniel Stokes](https://opencollective.com/daniel-stokes)
* [David Rose](https://opencollective.com/david-rose)
+* [Route4Me](https://route4me.com/)
## Benefactors
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 1d1ced66a4..fba23f92d6 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -109,6 +109,7 @@ option(BUILD_DIRECT "Build the direct source tree." ON)
option(BUILD_PANDATOOL "Build the pandatool source tree." ON)
option(BUILD_CONTRIB "Build the contrib source tree." ON)
option(BUILD_MODELS "Build/install the built-in models." ON)
+option(BUILD_TOOLS "Build binary tools." ON)
# Include Panda3D packages
if(BUILD_DTOOL)
diff --git a/README.md b/README.md
index d6468943c6..c4a18ce8a3 100644
--- a/README.md
+++ b/README.md
@@ -2,11 +2,11 @@
[](https://opencollective.com/panda3d)
[](https://opencollective.com/panda3d)
-
-
Panda3D
=======
+
+
Panda3D is a game engine, a framework for 3D rendering and game development for
Python and C++ programs. Panda3D is open-source and free for any purpose,
including commercial ventures, thanks to its
@@ -168,7 +168,7 @@ Install the appropriate package for it (such as `python37` or `python38`) and
run the makepanda script with your chosen Python version:
```bash
-python3.7 makepanda/makepanda.py --everything --installer --no-egl --no-gles --no-gles2
+python3.11 makepanda/makepanda.py --everything --installer --no-egl --no-gles --no-gles2
```
If successful, this will produce a .pkg file in the root of the source
diff --git a/cmake/macros/Interrogate.cmake b/cmake/macros/Interrogate.cmake
index eea12f9568..5f26cebbe9 100644
--- a/cmake/macros/Interrogate.cmake
+++ b/cmake/macros/Interrogate.cmake
@@ -257,7 +257,7 @@ function(interrogate_sources target output database language_flags)
make_directory "${output_directory}"
COMMAND ${CMAKE_COMMAND} -E
make_directory "${database_directory}"
- COMMAND host_interrogate
+ COMMAND interrogate
-oc "${output}"
-od "${database}"
-srcdir "${srcdir}"
@@ -272,7 +272,7 @@ function(interrogate_sources target output database language_flags)
${include_flags}
${scan_sources}
- DEPENDS host_interrogate ${sources} ${extensions} ${nfiles}
+ DEPENDS interrogate ${sources} ${extensions} ${nfiles}
COMMENT "Interrogating ${target}")
# Propagate the target's compile definitions to the output file
@@ -362,13 +362,13 @@ function(add_python_module module)
OUTPUT "${CMAKE_CURRENT_BINARY_DIR}/${PANDA_CFG_INTDIR}/${module}_module.cxx"
COMMAND ${CMAKE_COMMAND} -E
make_directory "${CMAKE_CURRENT_BINARY_DIR}/${PANDA_CFG_INTDIR}"
- COMMAND host_interrogate_module
+ COMMAND interrogate_module
-oc "${CMAKE_CURRENT_BINARY_DIR}/${PANDA_CFG_INTDIR}/${module}_module.cxx"
-module ${module} -library ${modname}
${import_flags}
${INTERROGATE_MODULE_OPTIONS}
${IMOD_FLAGS} ${infiles_rel}
- DEPENDS host_interrogate_module ${infiles_abs}
+ DEPENDS interrogate_module ${infiles_abs}
COMMENT "Generating module ${module}")
# CMake chokes on ${CMAKE_CFG_INTDIR} in source paths when unity builds are
diff --git a/direct/src/actor/Actor.py b/direct/src/actor/Actor.py
index 263ac8803a..cc81d525ca 100644
--- a/direct/src/actor/Actor.py
+++ b/direct/src/actor/Actor.py
@@ -737,6 +737,13 @@ class Actor(DirectObject, NodePath):
else:
return None
+ def getPlayMode(self, animName=None, partName=None):
+ if self.__animControlDict:
+ controls = self.getAnimControls(animName, partName, onlyPlaying=False)
+ if controls:
+ return controls[0].getPlayMode()
+ return None
+
def hasLOD(self):
"""
Return 1 if the actor has LODs, 0 otherwise
@@ -1762,7 +1769,7 @@ class Actor(DirectObject, NodePath):
return None
def getAnimControls(self, animName=None, partName=None, lodName=None,
- allowAsyncBind = True):
+ allowAsyncBind = True, onlyPlaying = True):
"""getAnimControls(self, string, string=None, string=None)
Returns a list of the AnimControls that represent the given
@@ -1840,7 +1847,7 @@ class Actor(DirectObject, NodePath):
# get all playing animations
for thisPart, animDict in animDictItems:
for anim in animDict.values():
- if anim.animControl and anim.animControl.isPlaying():
+ if anim.animControl and (not onlyPlaying or anim.animControl.isPlaying()):
controls.append(anim.animControl)
else:
# get the named animation(s) only.
@@ -2660,3 +2667,4 @@ class Actor(DirectObject, NodePath):
get_base_frame_rate = getBaseFrameRate
remove_anim_control_dict = removeAnimControlDict
load_anims_on_all_lods = loadAnimsOnAllLODs
+ get_play_mode = getPlayMode
diff --git a/direct/src/dcparse/CMakeLists.txt b/direct/src/dcparse/CMakeLists.txt
index e5cdee5b18..b48d772c17 100644
--- a/direct/src/dcparse/CMakeLists.txt
+++ b/direct/src/dcparse/CMakeLists.txt
@@ -1,3 +1,7 @@
+if(NOT BUILD_TOOLS)
+ return()
+endif()
+
add_executable(p3dcparse dcparse.cxx)
target_link_libraries(p3dcparse p3direct)
install(TARGETS p3dcparse EXPORT Direct COMPONENT Direct DESTINATION ${CMAKE_INSTALL_BINDIR})
diff --git a/direct/src/dcparser/dcParser.cxx.prebuilt b/direct/src/dcparser/dcParser.cxx.prebuilt
index 6f4f167302..aeab2dc34c 100644
--- a/direct/src/dcparser/dcParser.cxx.prebuilt
+++ b/direct/src/dcparser/dcParser.cxx.prebuilt
@@ -179,7 +179,7 @@ dc_cleanup_parser() {
# endif
# endif
-#include "dcParser.yxx.h"
+#include "dcParser.h"
/* Symbol kind. */
enum yysymbol_kind_t
{
diff --git a/direct/src/showbase/Transitions.py b/direct/src/showbase/Transitions.py
index aa79e4b38b..159e62f3b2 100644
--- a/direct/src/showbase/Transitions.py
+++ b/direct/src/showbase/Transitions.py
@@ -264,6 +264,54 @@ class Transitions:
self.iris = base.loader.loadModel(self.IrisModelName)
self.iris.setPos(0, 0, 0)
+ def getIrisInIval(self, t=0.5, finishIval=None, blendType='noBlend'):
+ """
+ Returns an interval without starting it. This is particularly useful in
+ cutscenes, so when the cutsceneIval is escaped out of we can finish the iris immediately
+ """
+ self.noTransitions()
+ self.loadIris()
+
+ scale = 0.18 * max(base.a2dRight, base.a2dTop)
+ transitionIval = Sequence(Func(self.iris.reparentTo, ShowBaseGlobal.aspect2d, DGG.FADE_SORT_INDEX),
+ LerpScaleInterval(self.iris, t,
+ scale = scale,
+ startScale = 0.01,
+ blendType=blendType),
+ Func(self.iris.detachNode),
+ Func(self.__finishTransition),
+ name = self.irisTaskName,
+ )
+ if finishIval:
+ transitionIval.append(finishIval)
+ return transitionIval
+
+ def getIrisOutIval(self, t=0.5, finishIval=None, blendType='noBlend'):
+ """
+ Create a sequence that lerps the iris out, then
+ parents the iris to hidden
+ """
+ self.noTransitions()
+ self.loadIris()
+ self.loadFade() # we need this to cover up the hole.
+
+ scale = 0.18 * max(base.a2dRight, base.a2dTop)
+ transitionIval = Sequence(Func(self.iris.reparentTo, ShowBaseGlobal.aspect2d, DGG.FADE_SORT_INDEX),
+ LerpScaleInterval(self.iris, t,
+ scale = 0.01,
+ startScale = scale,
+ blendType=blendType),
+ Func(self.iris.detachNode),
+ # Use the fade to cover up the hole that the iris would leave
+ Func(self.fadeOut, 0),
+ Func(self.__finishTransition),
+ name = self.irisTaskName,
+ )
+
+ if finishIval:
+ transitionIval.append(finishIval)
+ return transitionIval
+
def irisIn(self, t=0.5, finishIval=None, blendType = 'noBlend'):
"""
Play an iris in transition over t seconds.
@@ -271,25 +319,13 @@ class Transitions:
of the iris polygon up so it looks like we iris in. When the
scale lerp is finished, it parents the iris polygon to hidden.
"""
- self.noTransitions()
- self.loadIris()
if t == 0:
self.iris.detachNode()
fut = AsyncFuture()
fut.setResult(None)
return fut
else:
- self.iris.reparentTo(ShowBaseGlobal.aspect2d, DGG.FADE_SORT_INDEX)
-
- scale = 0.18 * max(base.a2dRight, base.a2dTop)
- self.transitionIval = Sequence(LerpScaleInterval(self.iris, t,
- scale = scale,
- startScale = 0.01,
- blendType=blendType),
- Func(self.iris.detachNode),
- Func(self.__finishTransition),
- name = self.irisTaskName,
- )
+ self.transitionIval = self.getIrisInIval(t, finishIval, blendType)
self.__transitionFuture = AsyncFuture()
if finishIval:
self.transitionIval.append(finishIval)
@@ -304,9 +340,6 @@ class Transitions:
lerp is finished, it leaves the iris polygon covering the
aspect2d plane until you irisIn or call noIris.
"""
- self.noTransitions()
- self.loadIris()
- self.loadFade() # we need this to cover up the hole.
if t == 0:
self.iris.detachNode()
self.fadeOut(0)
@@ -314,19 +347,7 @@ class Transitions:
fut.setResult(None)
return fut
else:
- self.iris.reparentTo(ShowBaseGlobal.aspect2d, DGG.FADE_SORT_INDEX)
-
- scale = 0.18 * max(base.a2dRight, base.a2dTop)
- self.transitionIval = Sequence(LerpScaleInterval(self.iris, t,
- scale = 0.01,
- startScale = scale,
- blendType=blendType),
- Func(self.iris.detachNode),
- # Use the fade to cover up the hole that the iris would leave
- Func(self.fadeOut, 0),
- Func(self.__finishTransition),
- name = self.irisTaskName,
- )
+ self.transitionIval = self.getIrisOutIval(t, finishIval, blendType)
self.__transitionFuture = AsyncFuture()
if finishIval:
self.transitionIval.append(finishIval)
diff --git a/dtool/CMakeLists.txt b/dtool/CMakeLists.txt
index 62308bd980..36e93a0be3 100644
--- a/dtool/CMakeLists.txt
+++ b/dtool/CMakeLists.txt
@@ -2,11 +2,9 @@
include(LocalSetup.cmake)
# Include dtool source directories
-add_subdirectory(src/cppparser)
add_subdirectory(src/dconfig)
add_subdirectory(src/dtoolbase)
add_subdirectory(src/dtoolutil)
-add_subdirectory(src/interrogate)
add_subdirectory(src/interrogatedb)
add_subdirectory(src/prc)
diff --git a/dtool/Config.cmake b/dtool/Config.cmake
index d269b62e3e..771e105be5 100644
--- a/dtool/Config.cmake
+++ b/dtool/Config.cmake
@@ -221,12 +221,6 @@ mark_as_advanced(DEFAULT_PRC_DIR PRC_DIR_ENVVARS PRC_PATH_ENVVARS
# The following options relate to interrogate, the tool that is
# used to generate bindings for non-C++ languages.
-option(WANT_INTERROGATE
- "Do you want to include Interrogate in the installation? This
-program reads C++ source files and generates bindings for another
-language. If you won't be building interfaces for other languages,
-you don't need the program." ON)
-
cmake_dependent_option(INTERROGATE_PYTHON_INTERFACE
"Do you want to generate a Python-callable interrogate interface?
This is only necessary if you plan to make calls into Panda from a
@@ -249,8 +243,79 @@ option(INTERROGATE_VERBOSE
"Set this if you would like interrogate to generate advanced
debugging information." OFF)
+set(_default_build_interrogate OFF)
+if (INTERROGATE_C_INTERFACE OR INTERROGATE_PYTHON_INTERFACE)
+ set(_default_build_interrogate ON)
+endif()
+
+option(BUILD_INTERROGATE
+ "Do you want to build interrogate from source? This is necessary
+if you wish to build Python or other bindings around Panda3D's C++
+interface. Set this to false if you already have a compatible
+version of interrogate installed." ${_default_build_interrogate})
+
mark_as_advanced(INTERROGATE_OPTIONS)
+if(BUILD_INTERROGATE)
+ include(ExternalProject)
+
+ set(_interrogate_dir "${PROJECT_BINARY_DIR}/interrogate")
+
+ ExternalProject_Add(
+ panda3d-interrogate
+
+ GIT_REPOSITORY https://github.com/panda3d/interrogate.git
+ GIT_TAG e297384b30f1eae8ab839ec096fc3bb6bdb3edeb
+
+ PREFIX ${_interrogate_dir}
+ CMAKE_ARGS
+ -DHAVE_PYTHON=OFF
+ -DBUILD_SHARED_LIBS=OFF
+ -DCMAKE_INSTALL_PREFIX:PATH=
+
+ EXCLUDE_FROM_ALL ON
+ BUILD_BYPRODUCTS "${_interrogate_dir}/bin/interrogate"
+ "${_interrogate_dir}/bin/interrogate_module"
+ )
+
+ add_executable(interrogate IMPORTED GLOBAL)
+ add_dependencies(interrogate panda3d-interrogate)
+ set_target_properties(interrogate PROPERTIES IMPORTED_LOCATION "${_interrogate_dir}/bin/interrogate")
+
+ add_executable(interrogate_module IMPORTED GLOBAL)
+ add_dependencies(interrogate_module panda3d-interrogate)
+ set_target_properties(interrogate_module PROPERTIES IMPORTED_LOCATION "${_interrogate_dir}/bin/interrogate_module")
+
+else()
+ find_program(INTERROGATE_EXECUTABLE interrogate)
+ find_program(INTERROGATE_MODULE_EXECUTABLE interrogate_module)
+
+ add_executable(interrogate IMPORTED GLOBAL)
+ if(INTERROGATE_EXECUTABLE)
+ set_target_properties(interrogate PROPERTIES
+ IMPORTED_LOCATION "${INTERROGATE_EXECUTABLE}")
+
+ elseif(INTERROGATE_PYTHON_INTERFACE OR INTERROGATE_C_INTERFACE)
+ message(FATAL_ERROR
+ "Requested interrogate bindings, but interrogate not found. Set "
+ "BUILD_INTERROGATE to build interrogate from source, or set "
+ "INTERROGATE_EXECUTABLE to the location of this tool.")
+ endif()
+
+ add_executable(interrogate_module IMPORTED GLOBAL)
+ if(INTERROGATE_MODULE_EXECUTABLE)
+ set_target_properties(interrogate_module PROPERTIES
+ IMPORTED_LOCATION "${INTERROGATE_MODULE_EXECUTABLE}")
+
+ elseif(INTERROGATE_PYTHON_INTERFACE)
+ message(FATAL_ERROR
+ "Requested interrogate bindings, but interrogate not found. Set "
+ "BUILD_INTERROGATE to build interrogate from source, or set "
+ "INTERROGATE_MODULE_EXECUTABLE to the location of this tool.")
+ endif()
+
+endif()
+
#
# The following options have to do with optional debugging features.
#
diff --git a/dtool/dtool_config.h.in b/dtool/dtool_config.h.in
index f115e022c3..2c17884407 100644
--- a/dtool/dtool_config.h.in
+++ b/dtool/dtool_config.h.in
@@ -24,9 +24,6 @@
/* Define to use doubles for most numbers, intead of single-precision floats. */
#cmakedefine STDFLOAT_DOUBLE
-/* Define if we have built libRocket available and built with Python support. */
-#cmakedefine HAVE_ROCKET_PYTHON
-
/* Define if we have ARToolKit available. */
#cmakedefine HAVE_ARTOOLKIT
diff --git a/dtool/src/cppparser/CMakeLists.txt b/dtool/src/cppparser/CMakeLists.txt
deleted file mode 100644
index 08563df508..0000000000
--- a/dtool/src/cppparser/CMakeLists.txt
+++ /dev/null
@@ -1,46 +0,0 @@
-set(P3CPPPARSER_HEADERS
- cppAttributeList.h
- cppArrayType.h cppBison.yxx cppBisonDefs.h
- cppClassTemplateParameter.h cppCommentBlock.h
- cppClosureType.h cppConstType.h
- cppDeclaration.h cppEnumType.h cppExpression.h
- cppExpressionParser.h cppExtensionType.h cppFile.h
- cppFunctionGroup.h cppFunctionType.h cppGlobals.h
- cppIdentifier.h cppInstance.h cppInstanceIdentifier.h
- cppMakeProperty.h cppMakeSeq.h cppManifest.h
- cppNameComponent.h cppNamespace.h
- cppParameterList.h cppParser.h cppPointerType.h
- cppPreprocessor.h cppReferenceType.h cppScope.h
- cppSimpleType.h cppStructType.h cppTBDType.h
- cppTemplateParameterList.h cppTemplateScope.h cppToken.h
- cppType.h cppTypeDeclaration.h cppTypeParser.h
- cppTypeProxy.h cppTypedefType.h cppUsing.h cppVisibility.h
-)
-
-set(P3CPPPARSER_SOURCES
- cppAttributeList.cxx
- cppArrayType.cxx ${CMAKE_CURRENT_BINARY_DIR}/cppBison.cxx
- cppClassTemplateParameter.cxx
- cppCommentBlock.cxx cppClosureType.cxx cppConstType.cxx cppDeclaration.cxx
- cppEnumType.cxx cppExpression.cxx cppExpressionParser.cxx
- cppExtensionType.cxx cppFile.cxx cppFunctionGroup.cxx
- cppFunctionType.cxx cppGlobals.cxx cppIdentifier.cxx
- cppInstance.cxx cppInstanceIdentifier.cxx
- cppMakeProperty.cxx cppMakeSeq.cxx cppManifest.cxx
- cppNameComponent.cxx cppNamespace.cxx cppParameterList.cxx
- cppParser.cxx cppPointerType.cxx cppPreprocessor.cxx
- cppReferenceType.cxx cppScope.cxx cppSimpleType.cxx
- cppStructType.cxx cppTBDType.cxx
- cppTemplateParameterList.cxx cppTemplateScope.cxx
- cppToken.cxx cppType.cxx cppTypeDeclaration.cxx
- cppTypeParser.cxx cppTypeProxy.cxx cppTypedefType.cxx
- cppUsing.cxx cppVisibility.cxx
-)
-
-add_bison_target(cppBison.cxx cppBison.yxx DEFINES cppBison.h PREFIX cppyy)
-
-composite_sources(p3cppParser P3CPPPARSER_SOURCES)
-add_library(p3cppParser STATIC ${P3CPPPARSER_HEADERS} ${P3CPPPARSER_SOURCES})
-target_link_libraries(p3cppParser p3dtool)
-
-install(TARGETS p3cppParser EXPORT Core COMPONENT CoreDevel DESTINATION ${CMAKE_INSTALL_LIBDIR})
diff --git a/dtool/src/cppparser/cppArrayType.cxx b/dtool/src/cppparser/cppArrayType.cxx
deleted file mode 100644
index efd06f17b6..0000000000
--- a/dtool/src/cppparser/cppArrayType.cxx
+++ /dev/null
@@ -1,269 +0,0 @@
-/**
- * PANDA 3D SOFTWARE
- * Copyright (c) Carnegie Mellon University. All rights reserved.
- *
- * All use of this software is subject to the terms of the revised BSD
- * license. You should have received a copy of this license along
- * with this source code in a file named "LICENSE."
- *
- * @file cppArrayType.cxx
- * @author drose
- * @date 1999-10-19
- */
-
-#include "cppArrayType.h"
-#include "cppExpression.h"
-#include "cppPointerType.h"
-
-/**
- *
- */
-CPPArrayType::
-CPPArrayType(CPPType *element_type, CPPExpression *bounds) :
- CPPType(CPPFile()),
- _element_type(element_type),
- _bounds(bounds)
-{
-}
-
-/**
- * Returns true if this declaration is an actual, factual declaration, or
- * false if some part of the declaration depends on a template parameter which
- * has not yet been instantiated.
- */
-bool CPPArrayType::
-is_fully_specified() const {
- return CPPType::is_fully_specified() &&
- _element_type->is_fully_specified();
-}
-
-/**
- * If this CPPType object is a forward reference or other nonspecified
- * reference to a type that might now be known a real type, returns the real
- * type. Otherwise returns the type itself.
- */
-CPPType *CPPArrayType::
-resolve_type(CPPScope *current_scope, CPPScope *global_scope) {
- CPPType *ptype = _element_type->resolve_type(current_scope, global_scope);
-
- if (ptype != _element_type) {
- CPPArrayType *rep = new CPPArrayType(*this);
- rep->_element_type = ptype;
- return CPPType::new_type(rep);
- }
- return this;
-}
-
-/**
- * Returns true if the type, or any nested type within the type, is a
- * CPPTBDType and thus isn't fully determined right now. In this case,
- * calling resolve_type() may or may not resolve the type.
- */
-bool CPPArrayType::
-is_tbd() const {
- return _element_type->is_tbd();
-}
-
-/**
- * Returns true if the type is considered a standard layout type.
- */
-bool CPPArrayType::
-is_standard_layout() const {
- return _element_type->is_standard_layout();
-}
-
-/**
- * Returns true if the type is considered a Plain Old Data (POD) type.
- */
-bool CPPArrayType::
-is_trivial() const {
- return _element_type->is_trivial();
-}
-
-/**
- * Returns true if the type can be safely copied by memcpy or memmove.
- */
-bool CPPArrayType::
-is_trivially_copyable() const {
- return _element_type->is_trivially_copyable();
-}
-
-/**
- * Returns true if the type is default-constructible.
- */
-bool CPPArrayType::
-is_default_constructible() const {
- return _bounds != nullptr && _element_type->is_default_constructible();
-}
-
-/**
- * Returns true if the type is copy-constructible.
- */
-bool CPPArrayType::
-is_copy_constructible() const {
- // This is technically not exactly true, but array data members do not
- // prevent C++ implicit copy constructor generation rules, so we need to
- // return true here.
- // If this is a problem, we will need to create a separate method for the
- // purpose of checking copyability as a data member.
- return true;
-}
-
-/**
- * Returns true if the type is copy-assignable.
- */
-bool CPPArrayType::
-is_copy_assignable() const {
- // Same story as is_copy_constructible.
- return true;
-}
-
-/**
- * This is a little more forgiving than is_equal(): it returns true if the
- * types appear to be referring to the same thing, even if they may have
- * different pointers or somewhat different definitions. It's useful for
- * parameter matching, etc.
- */
-bool CPPArrayType::
-is_equivalent(const CPPType &other) const {
- const CPPArrayType *ot = ((CPPType *)&other)->as_array_type();
- if (ot == nullptr) {
- return CPPType::is_equivalent(other);
- }
-
- return _element_type->is_equivalent(*ot->_element_type);
-}
-
-/**
- *
- */
-CPPDeclaration *CPPArrayType::
-substitute_decl(CPPDeclaration::SubstDecl &subst,
- CPPScope *current_scope, CPPScope *global_scope) {
- SubstDecl::const_iterator si = subst.find(this);
- if (si != subst.end()) {
- return (*si).second;
- }
-
- CPPArrayType *rep = new CPPArrayType(*this);
- rep->_element_type =
- _element_type->substitute_decl(subst, current_scope, global_scope)
- ->as_type();
-
- if (_bounds != nullptr) {
- rep->_bounds =
- _bounds->substitute_decl(subst, current_scope, global_scope)
- ->as_expression();
- }
-
- if (rep->_element_type == _element_type &&
- rep->_bounds == _bounds) {
- delete rep;
- rep = this;
- }
- rep = CPPType::new_type(rep)->as_array_type();
- subst.insert(SubstDecl::value_type(this, rep));
- return rep;
-}
-
-/**
- *
- */
-void CPPArrayType::
-output(std::ostream &out, int indent_level, CPPScope *scope, bool complete) const {
- /*
- _element_type->output(out, indent_level, scope, complete);
- out << "[";
- if (_bounds != NULL) {
- out << *_bounds;
- }
- out << "]";
- */
- output_instance(out, indent_level, scope, complete, "", "");
-}
-
-/**
- * Formats a C++-looking line that defines an instance of the given type, with
- * the indicated name. In most cases this will be "type name", but some types
- * have special exceptions.
- */
-void CPPArrayType::
-output_instance(std::ostream &out, int indent_level, CPPScope *scope,
- bool complete, const std::string &prename,
- const std::string &name) const {
- std::ostringstream brackets;
- brackets << "[";
- if (_bounds != nullptr) {
- brackets << *_bounds;
- }
- brackets << "]";
-
- if (!_attributes.is_empty()) {
- brackets << " " << _attributes;
- }
-
- std::string bracketsstr = brackets.str();
-
- _element_type->output_instance(out, indent_level, scope, complete,
- prename, name + bracketsstr);
-}
-
-/**
- *
- */
-CPPDeclaration::SubType CPPArrayType::
-get_subtype() const {
- return ST_array;
-}
-
-/**
- *
- */
-CPPArrayType *CPPArrayType::
-as_array_type() {
- return this;
-}
-
-/**
- * Called by CPPDeclaration() to determine whether this type is equivalent to
- * another type of the same type.
- */
-bool CPPArrayType::
-is_equal(const CPPDeclaration *other) const {
- const CPPArrayType *ot = ((CPPDeclaration *)other)->as_array_type();
- assert(ot != nullptr);
-
- if (_bounds != nullptr && ot->_bounds != nullptr) {
- if (*_bounds != *ot->_bounds) {
- return false;
- }
- } else if ((_bounds == nullptr) != (ot->_bounds == nullptr)) {
- return false;
- }
-
- return *_element_type == *ot->_element_type;
-}
-
-
-/**
- * Called by CPPDeclaration() to determine whether this type should be ordered
- * before another type of the same type, in an arbitrary but fixed ordering.
- */
-bool CPPArrayType::
-is_less(const CPPDeclaration *other) const {
- const CPPArrayType *ot = ((CPPDeclaration *)other)->as_array_type();
- assert(ot != nullptr);
-
- if (_bounds != nullptr && ot->_bounds != nullptr) {
- if (*_bounds != *ot->_bounds) {
- return *_bounds < *ot->_bounds;
- }
- } else if ((_bounds == nullptr) != (ot->_bounds == nullptr)) {
- return _bounds < ot->_bounds;
- }
-
- if (*_element_type != *ot->_element_type) {
- return *_element_type < *ot->_element_type;
- }
- return false;
-}
diff --git a/dtool/src/cppparser/cppArrayType.h b/dtool/src/cppparser/cppArrayType.h
deleted file mode 100644
index 56afed1cbf..0000000000
--- a/dtool/src/cppparser/cppArrayType.h
+++ /dev/null
@@ -1,65 +0,0 @@
-/**
- * PANDA 3D SOFTWARE
- * Copyright (c) Carnegie Mellon University. All rights reserved.
- *
- * All use of this software is subject to the terms of the revised BSD
- * license. You should have received a copy of this license along
- * with this source code in a file named "LICENSE."
- *
- * @file cppArrayType.h
- * @author drose
- * @date 1999-10-19
- */
-
-#ifndef CPPARRAYTYPE_H
-#define CPPARRAYTYPE_H
-
-#include "dtoolbase.h"
-
-#include "cppType.h"
-
-class CPPExpression;
-
-/**
- *
- */
-class CPPArrayType : public CPPType {
-public:
- CPPArrayType(CPPType *element_type, CPPExpression *bounds);
-
- CPPType *_element_type;
- CPPExpression *_bounds;
-
- virtual bool is_fully_specified() const;
- virtual CPPDeclaration *substitute_decl(SubstDecl &subst,
- CPPScope *current_scope,
- CPPScope *global_scope);
-
- virtual CPPType *resolve_type(CPPScope *current_scope,
- CPPScope *global_scope);
- virtual bool is_tbd() const;
- virtual bool is_standard_layout() const;
- virtual bool is_trivial() const;
- virtual bool is_trivially_copyable() const;
- virtual bool is_default_constructible() const;
- virtual bool is_copy_constructible() const;
- virtual bool is_copy_assignable() const;
- virtual bool is_equivalent(const CPPType &other) const;
-
- virtual void output(std::ostream &out, int indent_level, CPPScope *scope,
- bool complete) const;
- virtual void output_instance(std::ostream &out, int indent_level,
- CPPScope *scope,
- bool complete, const std::string &prename,
- const std::string &name) const;
-
- virtual SubType get_subtype() const;
-
- virtual CPPArrayType *as_array_type();
-
-protected:
- virtual bool is_equal(const CPPDeclaration *other) const;
- virtual bool is_less(const CPPDeclaration *other) const;
-};
-
-#endif
diff --git a/dtool/src/cppparser/cppAttributeList.cxx b/dtool/src/cppparser/cppAttributeList.cxx
deleted file mode 100644
index 6a280d3cd7..0000000000
--- a/dtool/src/cppparser/cppAttributeList.cxx
+++ /dev/null
@@ -1,196 +0,0 @@
-/**
- * PANDA 3D SOFTWARE
- * Copyright (c) Carnegie Mellon University. All rights reserved.
- *
- * All use of this software is subject to the terms of the revised BSD
- * license. You should have received a copy of this license along
- * with this source code in a file named "LICENSE."
- *
- * @file cppAttributeList.cxx
- * @author rdb
- * @date 2022-10-23
- */
-
-#include "cppAttributeList.h"
-#include "cppExpression.h"
-#include "cppIdentifier.h"
-#include "cppType.h"
-
-/**
- * Returns true if no attributes have been defined.
- */
-bool CPPAttributeList::
-is_empty() const {
- return _attributes.empty() && _alignas == nullptr;
-}
-
-/**
- * Returns true if the attribute list has an attribute with the given name.
- */
-bool CPPAttributeList::
-has_attribute(const std::string &name) const {
- for (const Attribute &attr : _attributes) {
- if (attr._ident->get_fully_scoped_name() == name) {
- return true;
- }
- }
- return false;
-}
-
-/**
- *
- */
-bool CPPAttributeList::
-operator == (const CPPAttributeList &other) const {
- if (_attributes.size() != other._attributes.size()) {
- return false;
- }
- if ((_alignas != nullptr) != (other._alignas != nullptr)) {
- return false;
- }
- if (_alignas != nullptr && *_alignas != *other._alignas) {
- return false;
- }
- for (size_t i = 0; i < _attributes.size(); ++i) {
- if (_attributes[i]._ident != other._attributes[i]._ident) {
- return false;
- }
- if (_attributes[i]._reason != other._attributes[i]._reason) {
- return false;
- }
- }
- return true;
-}
-
-/**
- *
- */
-bool CPPAttributeList::
-operator != (const CPPAttributeList &other) const {
- return !(*this == other);
-}
-
-/**
- *
- */
-bool CPPAttributeList::
-operator < (const CPPAttributeList &other) const {
- if (_attributes.size() != other._attributes.size()) {
- return _attributes.size() < other._attributes.size();
- }
- if ((_alignas != nullptr) != (other._alignas != nullptr)) {
- return _alignas == nullptr;
- }
- if (_alignas != nullptr && *_alignas != *other._alignas) {
- return *_alignas < *other._alignas;
- }
- for (size_t i = 0; i < _attributes.size(); ++i) {
- if (_attributes[i]._ident != other._attributes[i]._ident) {
- return _attributes[i]._ident < other._attributes[i]._ident;
- }
- if (_attributes[i]._reason != other._attributes[i]._reason) {
- return _attributes[i]._reason < other._attributes[i]._reason;
- }
- }
- return false;
-}
-
-/**
- * Adds an attribute.
- */
-void CPPAttributeList::
-add_attribute(CPPIdentifier *ident) {
- _attributes.push_back({ident});
-}
-
-/**
- * Adds an attribute.
- */
-void CPPAttributeList::
-add_attribute(CPPIdentifier *ident, std::string reason) {
- _attributes.push_back({ident, std::move(reason)});
-}
-
-/**
- * Adds an alignas specifier.
- */
-void CPPAttributeList::
-add_alignas(int size) {
- if (_alignas == nullptr || size >= _alignas->evaluate().as_integer()) {
- _alignas = new CPPExpression(size);
- }
-}
-
-/**
- * Adds an alignas specifier.
- */
-void CPPAttributeList::
-add_alignas(CPPType *type) {
- CPPExpression expr = CPPExpression::alignof_func(type);
- if (_alignas == nullptr || expr.evaluate().as_integer() > _alignas->evaluate().as_integer()) {
- _alignas = new CPPExpression(expr);
- }
-}
-
-/**
- * Adds an alignas specifier.
- */
-void CPPAttributeList::
-add_alignas(CPPExpression *expr) {
- if (_alignas == nullptr || expr->evaluate().as_integer() > _alignas->evaluate().as_integer()) {
- _alignas = expr;
- }
-}
-
-/**
- * Merges the other list into this one.
- */
-void CPPAttributeList::
-add_attributes_from(const CPPAttributeList &other) {
- for (const Attribute &attr : other._attributes) {
- _attributes.push_back(attr);
- }
-
- if (other._alignas != nullptr) {
- add_alignas(other._alignas);
- }
-}
-
-/**
- *
- */
-void CPPAttributeList::
-output(std::ostream &out, CPPScope *scope) const {
- Attributes::const_iterator it = _attributes.begin();
- if (it != _attributes.end()) {
- out << "[[";
- (*it)._ident->output(out, scope);
- if (!(*it)._reason.empty()) {
- out << "(" << (*it)._reason << ")";
- }
-
- for (++it; it != _attributes.end(); ++it) {
- out << ", ";
- (*it)._ident->output(out, scope);
- if (!(*it)._reason.empty()) {
- out << "(" << (*it)._reason << ")";
- }
- }
-
- out << "]]";
-
- if (_alignas != nullptr) {
- out << " ";
- }
- }
-
- if (_alignas != nullptr) {
- out << "alignas(";
- if (_alignas->_type == CPPExpression::T_alignof) {
- _alignas->_u._typecast._to->output(out, 0, scope, false);
- } else {
- _alignas->output(out, 0, scope, false);
- }
- out << ")";
- }
-}
diff --git a/dtool/src/cppparser/cppAttributeList.h b/dtool/src/cppparser/cppAttributeList.h
deleted file mode 100644
index 9463b2b65c..0000000000
--- a/dtool/src/cppparser/cppAttributeList.h
+++ /dev/null
@@ -1,65 +0,0 @@
-/**
- * PANDA 3D SOFTWARE
- * Copyright (c) Carnegie Mellon University. All rights reserved.
- *
- * All use of this software is subject to the terms of the revised BSD
- * license. You should have received a copy of this license along
- * with this source code in a file named "LICENSE."
- *
- * @file cppAttributeList.h
- * @author rdb
- * @date 2022-10-23
- */
-
-#ifndef CPPATTRIBUTELIST_H
-#define CPPATTRIBUTELIST_H
-
-#include "dtoolbase.h"
-
-#include
-
-class CPPExpression;
-class CPPIdentifier;
-class CPPScope;
-class CPPType;
-
-/**
- * A list of square-bracket attributes and/or alignas specifiers.
- */
-class CPPAttributeList {
-public:
- bool is_empty() const;
- bool has_attribute(const std::string &name) const;
-
- bool operator == (const CPPAttributeList &other) const;
- bool operator != (const CPPAttributeList &other) const;
- bool operator < (const CPPAttributeList &other) const;
-
- void add_attribute(CPPIdentifier *ident);
- void add_attribute(CPPIdentifier *ident, std::string reason);
-
- void add_alignas(int size);
- void add_alignas(CPPType *type);
- void add_alignas(CPPExpression *expr);
-
- void add_attributes_from(const CPPAttributeList &other);
-
- struct Attribute {
- CPPIdentifier *_ident;
- std::string _reason;
- };
-
- typedef std::vector Attributes;
- Attributes _attributes;
- CPPExpression *_alignas = nullptr;
-
- void output(std::ostream &out, CPPScope *scope) const;
-};
-
-inline std::ostream &
-operator << (std::ostream &out, const CPPAttributeList &alist) {
- alist.output(out, nullptr);
- return out;
-}
-
-#endif
diff --git a/dtool/src/cppparser/cppBison.cxx.prebuilt b/dtool/src/cppparser/cppBison.cxx.prebuilt
deleted file mode 100644
index 0d94f44c79..0000000000
--- a/dtool/src/cppparser/cppBison.cxx.prebuilt
+++ /dev/null
@@ -1,10080 +0,0 @@
-/* A Bison parser, made by GNU Bison 3.8.2. */
-
-/* Bison implementation for Yacc-like parsers in C
-
- Copyright (C) 1984, 1989-1990, 2000-2015, 2018-2021 Free Software Foundation,
- Inc.
-
- This program is free software: you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation, either version 3 of the License, or
- (at your option) any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program. If not, see . */
-
-/* As a special exception, you may create a larger work that contains
- part or all of the Bison parser skeleton and distribute that work
- under terms of your choice, so long as that work isn't itself a
- parser generator using the skeleton or a modified version thereof
- as a parser skeleton. Alternatively, if you modify or redistribute
- the parser skeleton itself, you may (at your option) remove this
- special exception, which will cause the skeleton and the resulting
- Bison output files to be licensed under the GNU General Public
- License without this special exception.
-
- This special exception was added by the Free Software Foundation in
- version 2.2 of Bison. */
-
-/* C LALR(1) parser skeleton written by Richard Stallman, by
- simplifying the original so-called "semantic" parser. */
-
-/* DO NOT RELY ON FEATURES THAT ARE NOT DOCUMENTED in the manual,
- especially those whose name start with YY_ or yy_. They are
- private implementation details that can be changed or removed. */
-
-/* All symbols defined below should begin with yy or YY, to avoid
- infringing on user name space. This should be done even for local
- variables, as they might otherwise be expanded by user macros.
- There are some unavoidable exceptions within include files to
- define necessary library symbols; they are noted "INFRINGES ON
- USER NAME SPACE" below. */
-
-/* Identify Bison output, and Bison version. */
-#define YYBISON 30802
-
-/* Bison version string. */
-#define YYBISON_VERSION "3.8.2"
-
-/* Skeleton name. */
-#define YYSKELETON_NAME "yacc.c"
-
-/* Pure parsers. */
-#define YYPURE 2
-
-/* Push parsers. */
-#define YYPUSH 0
-
-/* Pull parsers. */
-#define YYPULL 1
-
-
-/* Substitute the variable and function names. */
-#define yyparse cppyyparse
-#define yylex cppyylex
-#define yyerror cppyyerror
-#define yydebug cppyydebug
-#define yynerrs cppyynerrs
-
-/* First part of user prologue. */
-#line 7 "dtool/src/cppparser/cppBison.yxx"
-
-
-#include "cppBisonDefs.h"
-#include "cppParser.h"
-#include "cppClosureType.h"
-#include "cppExpression.h"
-#include "cppSimpleType.h"
-#include "cppExtensionType.h"
-#include "cppStructType.h"
-#include "cppEnumType.h"
-#include "cppFunctionType.h"
-#include "cppTBDType.h"
-#include "cppMakeProperty.h"
-#include "cppMakeSeq.h"
-#include "cppParameterList.h"
-#include "cppInstance.h"
-#include "cppClassTemplateParameter.h"
-#include "cppTemplateParameterList.h"
-#include "cppInstanceIdentifier.h"
-#include "cppTypedefType.h"
-#include "cppTypeDeclaration.h"
-#include "cppVisibility.h"
-#include "cppIdentifier.h"
-#include "cppScope.h"
-#include "cppTemplateScope.h"
-#include "cppNamespace.h"
-#include "cppUsing.h"
-
-using std::stringstream;
-using std::string;
-
-////////////////////////////////////////////////////////////////////
-// Defining the interface to the parser.
-////////////////////////////////////////////////////////////////////
-
-CPPScope *current_scope = nullptr;
-CPPScope *global_scope = nullptr;
-CPPPreprocessor *current_lexer = nullptr;
-
-static CPPStructType *current_struct = nullptr;
-static CPPEnumType *current_enum = nullptr;
-static int current_storage_class = 0;
-static CPPType *current_type = nullptr;
-static CPPExpression *current_expr = nullptr;
-static CPPAttributeList current_attributes;
-static int publish_nest_level = 0;
-static CPPVisibility publish_previous;
-static YYLTYPE publish_loc;
-
-static std::vector last_scopes;
-static std::vector last_storage_classes;
-static std::vector last_structs;
-
-int yyparse();
-
-#define YYERROR_VERBOSE
-
-static void
-yyerror(const string &msg) {
- current_lexer->error(msg, current_lexer->_last_token_loc);
-}
-
-static void
-yyerror(YYLTYPE *loc, const string &msg) {
- current_lexer->error(msg, *loc);
-}
-
-static void
-yyerror(const string &msg, YYLTYPE &loc) {
- current_lexer->error(msg, loc);
-}
-
-static void
-yywarning(const string &msg, YYLTYPE &loc) {
- current_lexer->warning(msg, loc);
-}
-
-static int
-yylex(YYSTYPE *lval, YYLTYPE *lloc) {
- CPPToken token = current_lexer->get_next_token();
- *lval = token._lval;
- *lloc = token._lloc;
- return token._token;
-}
-
-void
-parse_cpp(CPPParser *cp) {
- CPPScope *old_scope = current_scope;
- CPPScope *old_global_scope = global_scope;
- CPPPreprocessor *old_lexer = current_lexer;
-
- current_scope = cp;
- global_scope = cp;
- current_lexer = cp;
- publish_nest_level = 0;
- yyparse();
-
- if (publish_nest_level != 0) {
- yyerror("Unclosed __begin_publish", publish_loc);
- publish_nest_level = 0;
- }
-
- current_scope = old_scope;
- global_scope = old_global_scope;
- current_lexer = old_lexer;
-
-}
-
-CPPExpression *
-parse_const_expr(CPPPreprocessor *pp, CPPScope *new_current_scope,
- CPPScope *new_global_scope) {
- CPPScope *old_scope = current_scope;
- CPPScope *old_global_scope = global_scope;
- CPPPreprocessor *old_lexer = current_lexer;
- CPPExpression *old_expr = current_expr;
-
- current_scope = new_current_scope;
- global_scope = new_global_scope;
- current_expr = nullptr;
- current_lexer = pp;
- yyparse();
-
- CPPExpression *result = current_expr;
-
- current_scope = old_scope;
- global_scope = old_global_scope;
- current_lexer = old_lexer;
- current_expr = old_expr;
-
- return result;
-}
-
-CPPType *
-parse_type(CPPPreprocessor *pp, CPPScope *new_current_scope,
- CPPScope *new_global_scope) {
- CPPScope *old_scope = current_scope;
- CPPScope *old_global_scope = global_scope;
- CPPPreprocessor *old_lexer = current_lexer;
- CPPType *old_type = current_type;
-
- current_scope = new_current_scope;
- global_scope = new_global_scope;
- current_type = nullptr;
- current_lexer = pp;
- yyparse();
-
- CPPType *result = current_type;
-
- current_scope = old_scope;
- global_scope = old_global_scope;
- current_lexer = old_lexer;
- current_type = old_type;
-
- return result;
-}
-
-static void
-push_scope(CPPScope *new_scope) {
- last_scopes.push_back(current_scope);
- if (new_scope != nullptr) {
- current_scope = new_scope;
- }
-}
-
-static void
-pop_scope() {
- assert(!last_scopes.empty());
- current_scope = last_scopes.back();
- last_scopes.pop_back();
-}
-
-static void
-push_storage_class(int new_storage_class) {
- last_storage_classes.push_back(current_storage_class);
- current_storage_class = new_storage_class;
-}
-
-static void
-pop_storage_class() {
- assert(!last_storage_classes.empty());
- current_storage_class = last_storage_classes.back();
- last_storage_classes.pop_back();
-}
-
-static void
-push_struct(CPPStructType *new_struct) {
- last_structs.push_back(current_struct);
- current_struct = new_struct;
-}
-
-static void
-pop_struct() {
- assert(!last_structs.empty());
- current_struct = last_structs.back();
- last_structs.pop_back();
-}
-
-
-#line 275 "built/tmp/cppBison.yxx.c"
-
-# ifndef YY_CAST
-# ifdef __cplusplus
-# define YY_CAST(Type, Val) static_cast (Val)
-# define YY_REINTERPRET_CAST(Type, Val) reinterpret_cast (Val)
-# else
-# define YY_CAST(Type, Val) ((Type) (Val))
-# define YY_REINTERPRET_CAST(Type, Val) ((Type) (Val))
-# endif
-# endif
-# ifndef YY_NULLPTR
-# if defined __cplusplus
-# if 201103L <= __cplusplus
-# define YY_NULLPTR nullptr
-# else
-# define YY_NULLPTR 0
-# endif
-# else
-# define YY_NULLPTR ((void*)0)
-# endif
-# endif
-
-#include "cppBison.yxx.h"
-/* Symbol kind. */
-enum yysymbol_kind_t
-{
- YYSYMBOL_YYEMPTY = -2,
- YYSYMBOL_YYEOF = 0, /* "end of file" */
- YYSYMBOL_YYerror = 1, /* error */
- YYSYMBOL_YYUNDEF = 2, /* "invalid token" */
- YYSYMBOL_REAL = 3, /* REAL */
- YYSYMBOL_INTEGER = 4, /* INTEGER */
- YYSYMBOL_CHAR_TOK = 5, /* CHAR_TOK */
- YYSYMBOL_SIMPLE_STRING = 6, /* SIMPLE_STRING */
- YYSYMBOL_SIMPLE_IDENTIFIER = 7, /* SIMPLE_IDENTIFIER */
- YYSYMBOL_STRING_LITERAL = 8, /* STRING_LITERAL */
- YYSYMBOL_CUSTOM_LITERAL = 9, /* CUSTOM_LITERAL */
- YYSYMBOL_IDENTIFIER = 10, /* IDENTIFIER */
- YYSYMBOL_TYPENAME_IDENTIFIER = 11, /* TYPENAME_IDENTIFIER */
- YYSYMBOL_TYPEPACK_IDENTIFIER = 12, /* TYPEPACK_IDENTIFIER */
- YYSYMBOL_SCOPING = 13, /* SCOPING */
- YYSYMBOL_TYPEDEFNAME = 14, /* TYPEDEFNAME */
- YYSYMBOL_ELLIPSIS = 15, /* ELLIPSIS */
- YYSYMBOL_OROR = 16, /* OROR */
- YYSYMBOL_ANDAND = 17, /* ANDAND */
- YYSYMBOL_EQCOMPARE = 18, /* EQCOMPARE */
- YYSYMBOL_NECOMPARE = 19, /* NECOMPARE */
- YYSYMBOL_LECOMPARE = 20, /* LECOMPARE */
- YYSYMBOL_GECOMPARE = 21, /* GECOMPARE */
- YYSYMBOL_SPACESHIP = 22, /* SPACESHIP */
- YYSYMBOL_LSHIFT = 23, /* LSHIFT */
- YYSYMBOL_RSHIFT = 24, /* RSHIFT */
- YYSYMBOL_POINTSAT_STAR = 25, /* POINTSAT_STAR */
- YYSYMBOL_DOT_STAR = 26, /* DOT_STAR */
- YYSYMBOL_UNARY = 27, /* UNARY */
- YYSYMBOL_UNARY_NOT = 28, /* UNARY_NOT */
- YYSYMBOL_UNARY_NEGATE = 29, /* UNARY_NEGATE */
- YYSYMBOL_UNARY_MINUS = 30, /* UNARY_MINUS */
- YYSYMBOL_UNARY_PLUS = 31, /* UNARY_PLUS */
- YYSYMBOL_UNARY_STAR = 32, /* UNARY_STAR */
- YYSYMBOL_UNARY_REF = 33, /* UNARY_REF */
- YYSYMBOL_POINTSAT = 34, /* POINTSAT */
- YYSYMBOL_SCOPE = 35, /* SCOPE */
- YYSYMBOL_PLUSPLUS = 36, /* PLUSPLUS */
- YYSYMBOL_MINUSMINUS = 37, /* MINUSMINUS */
- YYSYMBOL_TIMESEQUAL = 38, /* TIMESEQUAL */
- YYSYMBOL_DIVIDEEQUAL = 39, /* DIVIDEEQUAL */
- YYSYMBOL_MODEQUAL = 40, /* MODEQUAL */
- YYSYMBOL_PLUSEQUAL = 41, /* PLUSEQUAL */
- YYSYMBOL_MINUSEQUAL = 42, /* MINUSEQUAL */
- YYSYMBOL_OREQUAL = 43, /* OREQUAL */
- YYSYMBOL_ANDEQUAL = 44, /* ANDEQUAL */
- YYSYMBOL_XOREQUAL = 45, /* XOREQUAL */
- YYSYMBOL_LSHIFTEQUAL = 46, /* LSHIFTEQUAL */
- YYSYMBOL_RSHIFTEQUAL = 47, /* RSHIFTEQUAL */
- YYSYMBOL_ATTR_LEFT = 48, /* ATTR_LEFT */
- YYSYMBOL_ATTR_RIGHT = 49, /* ATTR_RIGHT */
- YYSYMBOL_KW_ALIGNAS = 50, /* KW_ALIGNAS */
- YYSYMBOL_KW_ALIGNOF = 51, /* KW_ALIGNOF */
- YYSYMBOL_KW_AUTO = 52, /* KW_AUTO */
- YYSYMBOL_KW_BEGIN_PUBLISH = 53, /* KW_BEGIN_PUBLISH */
- YYSYMBOL_KW_BLOCKING = 54, /* KW_BLOCKING */
- YYSYMBOL_KW_BOOL = 55, /* KW_BOOL */
- YYSYMBOL_KW_BUILTIN_VA_LIST = 56, /* KW_BUILTIN_VA_LIST */
- YYSYMBOL_KW_CATCH = 57, /* KW_CATCH */
- YYSYMBOL_KW_CHAR = 58, /* KW_CHAR */
- YYSYMBOL_KW_CHAR8_T = 59, /* KW_CHAR8_T */
- YYSYMBOL_KW_CHAR16_T = 60, /* KW_CHAR16_T */
- YYSYMBOL_KW_CHAR32_T = 61, /* KW_CHAR32_T */
- YYSYMBOL_KW_CLASS = 62, /* KW_CLASS */
- YYSYMBOL_KW_CONST = 63, /* KW_CONST */
- YYSYMBOL_KW_CONSTEVAL = 64, /* KW_CONSTEVAL */
- YYSYMBOL_KW_CONSTEXPR = 65, /* KW_CONSTEXPR */
- YYSYMBOL_KW_CONSTINIT = 66, /* KW_CONSTINIT */
- YYSYMBOL_KW_CONST_CAST = 67, /* KW_CONST_CAST */
- YYSYMBOL_KW_DECLTYPE = 68, /* KW_DECLTYPE */
- YYSYMBOL_KW_DEFAULT = 69, /* KW_DEFAULT */
- YYSYMBOL_KW_DELETE = 70, /* KW_DELETE */
- YYSYMBOL_KW_DOUBLE = 71, /* KW_DOUBLE */
- YYSYMBOL_KW_DYNAMIC_CAST = 72, /* KW_DYNAMIC_CAST */
- YYSYMBOL_KW_ELSE = 73, /* KW_ELSE */
- YYSYMBOL_KW_END_PUBLISH = 74, /* KW_END_PUBLISH */
- YYSYMBOL_KW_ENUM = 75, /* KW_ENUM */
- YYSYMBOL_KW_EXTENSION = 76, /* KW_EXTENSION */
- YYSYMBOL_KW_EXTERN = 77, /* KW_EXTERN */
- YYSYMBOL_KW_EXPLICIT = 78, /* KW_EXPLICIT */
- YYSYMBOL_KW_EXPLICIT_LPAREN = 79, /* KW_EXPLICIT_LPAREN */
- YYSYMBOL_KW_PUBLISHED = 80, /* KW_PUBLISHED */
- YYSYMBOL_KW_FALSE = 81, /* KW_FALSE */
- YYSYMBOL_KW_FINAL = 82, /* KW_FINAL */
- YYSYMBOL_KW_FLOAT = 83, /* KW_FLOAT */
- YYSYMBOL_KW_FRIEND = 84, /* KW_FRIEND */
- YYSYMBOL_KW_FOR = 85, /* KW_FOR */
- YYSYMBOL_KW_GOTO = 86, /* KW_GOTO */
- YYSYMBOL_KW_HAS_VIRTUAL_DESTRUCTOR = 87, /* KW_HAS_VIRTUAL_DESTRUCTOR */
- YYSYMBOL_KW_IF = 88, /* KW_IF */
- YYSYMBOL_KW_INLINE = 89, /* KW_INLINE */
- YYSYMBOL_KW_INT = 90, /* KW_INT */
- YYSYMBOL_KW_IS_ABSTRACT = 91, /* KW_IS_ABSTRACT */
- YYSYMBOL_KW_IS_BASE_OF = 92, /* KW_IS_BASE_OF */
- YYSYMBOL_KW_IS_CLASS = 93, /* KW_IS_CLASS */
- YYSYMBOL_KW_IS_CONSTRUCTIBLE = 94, /* KW_IS_CONSTRUCTIBLE */
- YYSYMBOL_KW_IS_CONVERTIBLE_TO = 95, /* KW_IS_CONVERTIBLE_TO */
- YYSYMBOL_KW_IS_DESTRUCTIBLE = 96, /* KW_IS_DESTRUCTIBLE */
- YYSYMBOL_KW_IS_EMPTY = 97, /* KW_IS_EMPTY */
- YYSYMBOL_KW_IS_ENUM = 98, /* KW_IS_ENUM */
- YYSYMBOL_KW_IS_FINAL = 99, /* KW_IS_FINAL */
- YYSYMBOL_KW_IS_FUNDAMENTAL = 100, /* KW_IS_FUNDAMENTAL */
- YYSYMBOL_KW_IS_POD = 101, /* KW_IS_POD */
- YYSYMBOL_KW_IS_POLYMORPHIC = 102, /* KW_IS_POLYMORPHIC */
- YYSYMBOL_KW_IS_STANDARD_LAYOUT = 103, /* KW_IS_STANDARD_LAYOUT */
- YYSYMBOL_KW_IS_TRIVIAL = 104, /* KW_IS_TRIVIAL */
- YYSYMBOL_KW_IS_TRIVIALLY_COPYABLE = 105, /* KW_IS_TRIVIALLY_COPYABLE */
- YYSYMBOL_KW_IS_UNION = 106, /* KW_IS_UNION */
- YYSYMBOL_KW_LONG = 107, /* KW_LONG */
- YYSYMBOL_KW_MAKE_MAP_KEYS_SEQ = 108, /* KW_MAKE_MAP_KEYS_SEQ */
- YYSYMBOL_KW_MAKE_MAP_PROPERTY = 109, /* KW_MAKE_MAP_PROPERTY */
- YYSYMBOL_KW_MAKE_PROPERTY = 110, /* KW_MAKE_PROPERTY */
- YYSYMBOL_KW_MAKE_PROPERTY2 = 111, /* KW_MAKE_PROPERTY2 */
- YYSYMBOL_KW_MAKE_SEQ = 112, /* KW_MAKE_SEQ */
- YYSYMBOL_KW_MAKE_SEQ_PROPERTY = 113, /* KW_MAKE_SEQ_PROPERTY */
- YYSYMBOL_KW_MUTABLE = 114, /* KW_MUTABLE */
- YYSYMBOL_KW_NAMESPACE = 115, /* KW_NAMESPACE */
- YYSYMBOL_KW_NEW = 116, /* KW_NEW */
- YYSYMBOL_KW_NOEXCEPT = 117, /* KW_NOEXCEPT */
- YYSYMBOL_KW_NOEXCEPT_LPAREN = 118, /* KW_NOEXCEPT_LPAREN */
- YYSYMBOL_KW_NULLPTR = 119, /* KW_NULLPTR */
- YYSYMBOL_KW_OPERATOR = 120, /* KW_OPERATOR */
- YYSYMBOL_KW_OVERRIDE = 121, /* KW_OVERRIDE */
- YYSYMBOL_KW_PRIVATE = 122, /* KW_PRIVATE */
- YYSYMBOL_KW_PROTECTED = 123, /* KW_PROTECTED */
- YYSYMBOL_KW_PUBLIC = 124, /* KW_PUBLIC */
- YYSYMBOL_KW_REGISTER = 125, /* KW_REGISTER */
- YYSYMBOL_KW_REINTERPRET_CAST = 126, /* KW_REINTERPRET_CAST */
- YYSYMBOL_KW_RESTRICT = 127, /* KW_RESTRICT */
- YYSYMBOL_KW_RETURN = 128, /* KW_RETURN */
- YYSYMBOL_KW_SHORT = 129, /* KW_SHORT */
- YYSYMBOL_KW_SIGNED = 130, /* KW_SIGNED */
- YYSYMBOL_KW_SIZEOF = 131, /* KW_SIZEOF */
- YYSYMBOL_KW_STATIC = 132, /* KW_STATIC */
- YYSYMBOL_KW_STATIC_ASSERT = 133, /* KW_STATIC_ASSERT */
- YYSYMBOL_KW_STATIC_CAST = 134, /* KW_STATIC_CAST */
- YYSYMBOL_KW_STRUCT = 135, /* KW_STRUCT */
- YYSYMBOL_KW_TEMPLATE = 136, /* KW_TEMPLATE */
- YYSYMBOL_KW_THREAD_LOCAL = 137, /* KW_THREAD_LOCAL */
- YYSYMBOL_KW_THROW = 138, /* KW_THROW */
- YYSYMBOL_KW_TRUE = 139, /* KW_TRUE */
- YYSYMBOL_KW_TRY = 140, /* KW_TRY */
- YYSYMBOL_KW_TYPEDEF = 141, /* KW_TYPEDEF */
- YYSYMBOL_KW_TYPEID = 142, /* KW_TYPEID */
- YYSYMBOL_KW_TYPENAME = 143, /* KW_TYPENAME */
- YYSYMBOL_KW_UNDERLYING_TYPE = 144, /* KW_UNDERLYING_TYPE */
- YYSYMBOL_KW_UNION = 145, /* KW_UNION */
- YYSYMBOL_KW_UNSIGNED = 146, /* KW_UNSIGNED */
- YYSYMBOL_KW_USING = 147, /* KW_USING */
- YYSYMBOL_KW_VIRTUAL = 148, /* KW_VIRTUAL */
- YYSYMBOL_KW_VOID = 149, /* KW_VOID */
- YYSYMBOL_KW_VOLATILE = 150, /* KW_VOLATILE */
- YYSYMBOL_KW_WCHAR_T = 151, /* KW_WCHAR_T */
- YYSYMBOL_KW_WHILE = 152, /* KW_WHILE */
- YYSYMBOL_START_CPP = 153, /* START_CPP */
- YYSYMBOL_START_CONST_EXPR = 154, /* START_CONST_EXPR */
- YYSYMBOL_START_TYPE = 155, /* START_TYPE */
- YYSYMBOL_156_ = 156, /* '{' */
- YYSYMBOL_157_ = 157, /* ',' */
- YYSYMBOL_158_ = 158, /* ';' */
- YYSYMBOL_159_ = 159, /* ':' */
- YYSYMBOL_160_ = 160, /* '=' */
- YYSYMBOL_161_ = 161, /* '?' */
- YYSYMBOL_162_ = 162, /* '|' */
- YYSYMBOL_163_ = 163, /* '^' */
- YYSYMBOL_164_ = 164, /* '&' */
- YYSYMBOL_165_ = 165, /* '<' */
- YYSYMBOL_166_ = 166, /* '>' */
- YYSYMBOL_167_ = 167, /* '+' */
- YYSYMBOL_168_ = 168, /* '-' */
- YYSYMBOL_169_ = 169, /* '*' */
- YYSYMBOL_170_ = 170, /* '/' */
- YYSYMBOL_171_ = 171, /* '%' */
- YYSYMBOL_172_ = 172, /* '~' */
- YYSYMBOL_173_ = 173, /* '.' */
- YYSYMBOL_174_ = 174, /* '(' */
- YYSYMBOL_175_ = 175, /* '[' */
- YYSYMBOL_176_ = 176, /* ')' */
- YYSYMBOL_177_ = 177, /* '}' */
- YYSYMBOL_178_ = 178, /* '!' */
- YYSYMBOL_179_ = 179, /* ']' */
- YYSYMBOL_YYACCEPT = 180, /* $accept */
- YYSYMBOL_grammar = 181, /* grammar */
- YYSYMBOL_cpp = 182, /* cpp */
- YYSYMBOL_183_1 = 183, /* $@1 */
- YYSYMBOL_constructor_inits = 184, /* constructor_inits */
- YYSYMBOL_constructor_init = 185, /* constructor_init */
- YYSYMBOL_extern_c = 186, /* extern_c */
- YYSYMBOL_187_2 = 187, /* $@2 */
- YYSYMBOL_declaration = 188, /* declaration */
- YYSYMBOL_friend_declaration = 189, /* friend_declaration */
- YYSYMBOL_190_3 = 190, /* $@3 */
- YYSYMBOL_storage_class = 191, /* storage_class */
- YYSYMBOL_optional_attributes = 192, /* optional_attributes */
- YYSYMBOL_attribute_specifiers = 193, /* attribute_specifiers */
- YYSYMBOL_attribute_specifier = 194, /* attribute_specifier */
- YYSYMBOL_type_like_declaration = 195, /* type_like_declaration */
- YYSYMBOL_196_4 = 196, /* $@4 */
- YYSYMBOL_197_5 = 197, /* $@5 */
- YYSYMBOL_multiple_instance_identifiers = 198, /* multiple_instance_identifiers */
- YYSYMBOL_typedef_declaration = 199, /* typedef_declaration */
- YYSYMBOL_200_6 = 200, /* $@6 */
- YYSYMBOL_typedef_instance_identifiers = 201, /* typedef_instance_identifiers */
- YYSYMBOL_constructor_prototype = 202, /* constructor_prototype */
- YYSYMBOL_203_7 = 203, /* $@7 */
- YYSYMBOL_204_8 = 204, /* $@8 */
- YYSYMBOL_205_9 = 205, /* $@9 */
- YYSYMBOL_function_prototype = 206, /* function_prototype */
- YYSYMBOL_207_10 = 207, /* $@10 */
- YYSYMBOL_208_11 = 208, /* $@11 */
- YYSYMBOL_209_12 = 209, /* $@12 */
- YYSYMBOL_210_13 = 210, /* $@13 */
- YYSYMBOL_211_14 = 211, /* $@14 */
- YYSYMBOL_function_post = 212, /* function_post */
- YYSYMBOL_function_operator = 213, /* function_operator */
- YYSYMBOL_more_template_declaration = 214, /* more_template_declaration */
- YYSYMBOL_template_declaration = 215, /* template_declaration */
- YYSYMBOL_216_15 = 216, /* $@15 */
- YYSYMBOL_template_formal_parameters = 217, /* template_formal_parameters */
- YYSYMBOL_template_nonempty_formal_parameters = 218, /* template_nonempty_formal_parameters */
- YYSYMBOL_typename_keyword = 219, /* typename_keyword */
- YYSYMBOL_template_formal_parameter = 220, /* template_formal_parameter */
- YYSYMBOL_template_formal_parameter_type = 221, /* template_formal_parameter_type */
- YYSYMBOL_instance_identifier = 222, /* instance_identifier */
- YYSYMBOL_223_16 = 223, /* $@16 */
- YYSYMBOL_instance_identifier_and_maybe_trailing_return_type = 224, /* instance_identifier_and_maybe_trailing_return_type */
- YYSYMBOL_maybe_trailing_return_type = 225, /* maybe_trailing_return_type */
- YYSYMBOL_maybe_comma_identifier = 226, /* maybe_comma_identifier */
- YYSYMBOL_function_parameter_list = 227, /* function_parameter_list */
- YYSYMBOL_function_parameters = 228, /* function_parameters */
- YYSYMBOL_formal_parameter_list = 229, /* formal_parameter_list */
- YYSYMBOL_formal_parameters = 230, /* formal_parameters */
- YYSYMBOL_template_parameter_maybe_initialize = 231, /* template_parameter_maybe_initialize */
- YYSYMBOL_maybe_initialize = 232, /* maybe_initialize */
- YYSYMBOL_maybe_initialize_or_constructor_body = 233, /* maybe_initialize_or_constructor_body */
- YYSYMBOL_maybe_initialize_or_function_body = 234, /* maybe_initialize_or_function_body */
- YYSYMBOL_structure_init = 235, /* structure_init */
- YYSYMBOL_structure_init_body = 236, /* structure_init_body */
- YYSYMBOL_function_parameter = 237, /* function_parameter */
- YYSYMBOL_formal_parameter = 238, /* formal_parameter */
- YYSYMBOL_not_paren_formal_parameter_identifier = 239, /* not_paren_formal_parameter_identifier */
- YYSYMBOL_formal_parameter_identifier = 240, /* formal_parameter_identifier */
- YYSYMBOL_parameter_pack_identifier = 241, /* parameter_pack_identifier */
- YYSYMBOL_not_paren_empty_instance_identifier = 242, /* not_paren_empty_instance_identifier */
- YYSYMBOL_empty_instance_identifier = 243, /* empty_instance_identifier */
- YYSYMBOL_type = 244, /* type */
- YYSYMBOL_type_pack = 245, /* type_pack */
- YYSYMBOL_type_decl = 246, /* type_decl */
- YYSYMBOL_predefined_type = 247, /* predefined_type */
- YYSYMBOL_var_type_decl = 248, /* var_type_decl */
- YYSYMBOL_full_type = 249, /* full_type */
- YYSYMBOL_anonymous_struct = 250, /* anonymous_struct */
- YYSYMBOL_251_17 = 251, /* $@17 */
- YYSYMBOL_named_struct = 252, /* named_struct */
- YYSYMBOL_253_18 = 253, /* $@18 */
- YYSYMBOL_maybe_final = 254, /* maybe_final */
- YYSYMBOL_maybe_class_derivation = 255, /* maybe_class_derivation */
- YYSYMBOL_class_derivation = 256, /* class_derivation */
- YYSYMBOL_base_specification = 257, /* base_specification */
- YYSYMBOL_enum = 258, /* enum */
- YYSYMBOL_259_19 = 259, /* $@19 */
- YYSYMBOL_enum_decl = 260, /* enum_decl */
- YYSYMBOL_enum_element_type = 261, /* enum_element_type */
- YYSYMBOL_enum_body_trailing_comma = 262, /* enum_body_trailing_comma */
- YYSYMBOL_enum_body = 263, /* enum_body */
- YYSYMBOL_enum_keyword = 264, /* enum_keyword */
- YYSYMBOL_struct_keyword = 265, /* struct_keyword */
- YYSYMBOL_namespace_declaration = 266, /* namespace_declaration */
- YYSYMBOL_267_20 = 267, /* $@20 */
- YYSYMBOL_268_21 = 268, /* $@21 */
- YYSYMBOL_using_declaration = 269, /* using_declaration */
- YYSYMBOL_simple_type = 270, /* simple_type */
- YYSYMBOL_simple_int_type = 271, /* simple_int_type */
- YYSYMBOL_simple_float_type = 272, /* simple_float_type */
- YYSYMBOL_simple_void_type = 273, /* simple_void_type */
- YYSYMBOL_code = 274, /* code */
- YYSYMBOL_275_22 = 275, /* $@22 */
- YYSYMBOL_code_block = 276, /* code_block */
- YYSYMBOL_element = 277, /* element */
- YYSYMBOL_optional_const_expr = 278, /* optional_const_expr */
- YYSYMBOL_optional_const_expr_comma = 279, /* optional_const_expr_comma */
- YYSYMBOL_const_expr_comma = 280, /* const_expr_comma */
- YYSYMBOL_no_angle_bracket_const_expr = 281, /* no_angle_bracket_const_expr */
- YYSYMBOL_const_expr = 282, /* const_expr */
- YYSYMBOL_const_operand = 283, /* const_operand */
- YYSYMBOL_formal_const_expr = 284, /* formal_const_expr */
- YYSYMBOL_formal_const_operand = 285, /* formal_const_operand */
- YYSYMBOL_capture_list = 286, /* capture_list */
- YYSYMBOL_capture = 287, /* capture */
- YYSYMBOL_class_derivation_name = 288, /* class_derivation_name */
- YYSYMBOL_name = 289, /* name */
- YYSYMBOL_name_no_final = 290, /* name_no_final */
- YYSYMBOL_string_literal = 291, /* string_literal */
- YYSYMBOL_empty = 292 /* empty */
-};
-typedef enum yysymbol_kind_t yysymbol_kind_t;
-
-
-
-
-#ifdef short
-# undef short
-#endif
-
-/* On compilers that do not define __PTRDIFF_MAX__ etc., make sure
- and (if available) are included
- so that the code can choose integer types of a good width. */
-
-#ifndef __PTRDIFF_MAX__
-# include /* INFRINGES ON USER NAME SPACE */
-# if defined __STDC_VERSION__ && 199901 <= __STDC_VERSION__
-# include /* INFRINGES ON USER NAME SPACE */
-# define YY_STDINT_H
-# endif
-#endif
-
-/* Narrow types that promote to a signed type and that can represent a
- signed or unsigned integer of at least N bits. In tables they can
- save space and decrease cache pressure. Promoting to a signed type
- helps avoid bugs in integer arithmetic. */
-
-#ifdef __INT_LEAST8_MAX__
-typedef __INT_LEAST8_TYPE__ yytype_int8;
-#elif defined YY_STDINT_H
-typedef int_least8_t yytype_int8;
-#else
-typedef signed char yytype_int8;
-#endif
-
-#ifdef __INT_LEAST16_MAX__
-typedef __INT_LEAST16_TYPE__ yytype_int16;
-#elif defined YY_STDINT_H
-typedef int_least16_t yytype_int16;
-#else
-typedef short yytype_int16;
-#endif
-
-/* Work around bug in HP-UX 11.23, which defines these macros
- incorrectly for preprocessor constants. This workaround can likely
- be removed in 2023, as HPE has promised support for HP-UX 11.23
- (aka HP-UX 11i v2) only through the end of 2022; see Table 2 of
- . */
-#ifdef __hpux
-# undef UINT_LEAST8_MAX
-# undef UINT_LEAST16_MAX
-# define UINT_LEAST8_MAX 255
-# define UINT_LEAST16_MAX 65535
-#endif
-
-#if defined __UINT_LEAST8_MAX__ && __UINT_LEAST8_MAX__ <= __INT_MAX__
-typedef __UINT_LEAST8_TYPE__ yytype_uint8;
-#elif (!defined __UINT_LEAST8_MAX__ && defined YY_STDINT_H \
- && UINT_LEAST8_MAX <= INT_MAX)
-typedef uint_least8_t yytype_uint8;
-#elif !defined __UINT_LEAST8_MAX__ && UCHAR_MAX <= INT_MAX
-typedef unsigned char yytype_uint8;
-#else
-typedef short yytype_uint8;
-#endif
-
-#if defined __UINT_LEAST16_MAX__ && __UINT_LEAST16_MAX__ <= __INT_MAX__
-typedef __UINT_LEAST16_TYPE__ yytype_uint16;
-#elif (!defined __UINT_LEAST16_MAX__ && defined YY_STDINT_H \
- && UINT_LEAST16_MAX <= INT_MAX)
-typedef uint_least16_t yytype_uint16;
-#elif !defined __UINT_LEAST16_MAX__ && USHRT_MAX <= INT_MAX
-typedef unsigned short yytype_uint16;
-#else
-typedef int yytype_uint16;
-#endif
-
-#ifndef YYPTRDIFF_T
-# if defined __PTRDIFF_TYPE__ && defined __PTRDIFF_MAX__
-# define YYPTRDIFF_T __PTRDIFF_TYPE__
-# define YYPTRDIFF_MAXIMUM __PTRDIFF_MAX__
-# elif defined PTRDIFF_MAX
-# ifndef ptrdiff_t
-# include /* INFRINGES ON USER NAME SPACE */
-# endif
-# define YYPTRDIFF_T ptrdiff_t
-# define YYPTRDIFF_MAXIMUM PTRDIFF_MAX
-# else
-# define YYPTRDIFF_T long
-# define YYPTRDIFF_MAXIMUM LONG_MAX
-# endif
-#endif
-
-#ifndef YYSIZE_T
-# ifdef __SIZE_TYPE__
-# define YYSIZE_T __SIZE_TYPE__
-# elif defined size_t
-# define YYSIZE_T size_t
-# elif defined __STDC_VERSION__ && 199901 <= __STDC_VERSION__
-# include /* INFRINGES ON USER NAME SPACE */
-# define YYSIZE_T size_t
-# else
-# define YYSIZE_T unsigned
-# endif
-#endif
-
-#define YYSIZE_MAXIMUM \
- YY_CAST (YYPTRDIFF_T, \
- (YYPTRDIFF_MAXIMUM < YY_CAST (YYSIZE_T, -1) \
- ? YYPTRDIFF_MAXIMUM \
- : YY_CAST (YYSIZE_T, -1)))
-
-#define YYSIZEOF(X) YY_CAST (YYPTRDIFF_T, sizeof (X))
-
-
-/* Stored state numbers (used for stacks). */
-typedef yytype_int16 yy_state_t;
-
-/* State numbers in computations. */
-typedef int yy_state_fast_t;
-
-#ifndef YY_
-# if defined YYENABLE_NLS && YYENABLE_NLS
-# if ENABLE_NLS
-# include /* INFRINGES ON USER NAME SPACE */
-# define YY_(Msgid) dgettext ("bison-runtime", Msgid)
-# endif
-# endif
-# ifndef YY_
-# define YY_(Msgid) Msgid
-# endif
-#endif
-
-
-#ifndef YY_ATTRIBUTE_PURE
-# if defined __GNUC__ && 2 < __GNUC__ + (96 <= __GNUC_MINOR__)
-# define YY_ATTRIBUTE_PURE __attribute__ ((__pure__))
-# else
-# define YY_ATTRIBUTE_PURE
-# endif
-#endif
-
-#ifndef YY_ATTRIBUTE_UNUSED
-# if defined __GNUC__ && 2 < __GNUC__ + (7 <= __GNUC_MINOR__)
-# define YY_ATTRIBUTE_UNUSED __attribute__ ((__unused__))
-# else
-# define YY_ATTRIBUTE_UNUSED
-# endif
-#endif
-
-/* Suppress unused-variable warnings by "using" E. */
-#if ! defined lint || defined __GNUC__
-# define YY_USE(E) ((void) (E))
-#else
-# define YY_USE(E) /* empty */
-#endif
-
-/* Suppress an incorrect diagnostic about yylval being uninitialized. */
-#if defined __GNUC__ && ! defined __ICC && 406 <= __GNUC__ * 100 + __GNUC_MINOR__
-# if __GNUC__ * 100 + __GNUC_MINOR__ < 407
-# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
- _Pragma ("GCC diagnostic push") \
- _Pragma ("GCC diagnostic ignored \"-Wuninitialized\"")
-# else
-# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
- _Pragma ("GCC diagnostic push") \
- _Pragma ("GCC diagnostic ignored \"-Wuninitialized\"") \
- _Pragma ("GCC diagnostic ignored \"-Wmaybe-uninitialized\"")
-# endif
-# define YY_IGNORE_MAYBE_UNINITIALIZED_END \
- _Pragma ("GCC diagnostic pop")
-#else
-# define YY_INITIAL_VALUE(Value) Value
-#endif
-#ifndef YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
-# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
-# define YY_IGNORE_MAYBE_UNINITIALIZED_END
-#endif
-#ifndef YY_INITIAL_VALUE
-# define YY_INITIAL_VALUE(Value) /* Nothing. */
-#endif
-
-#if defined __cplusplus && defined __GNUC__ && ! defined __ICC && 6 <= __GNUC__
-# define YY_IGNORE_USELESS_CAST_BEGIN \
- _Pragma ("GCC diagnostic push") \
- _Pragma ("GCC diagnostic ignored \"-Wuseless-cast\"")
-# define YY_IGNORE_USELESS_CAST_END \
- _Pragma ("GCC diagnostic pop")
-#endif
-#ifndef YY_IGNORE_USELESS_CAST_BEGIN
-# define YY_IGNORE_USELESS_CAST_BEGIN
-# define YY_IGNORE_USELESS_CAST_END
-#endif
-
-
-#define YY_ASSERT(E) ((void) (0 && (E)))
-
-#if !defined yyoverflow
-
-/* The parser invokes alloca or malloc; define the necessary symbols. */
-
-# ifdef YYSTACK_USE_ALLOCA
-# if YYSTACK_USE_ALLOCA
-# ifdef __GNUC__
-# define YYSTACK_ALLOC __builtin_alloca
-# elif defined __BUILTIN_VA_ARG_INCR
-# include /* INFRINGES ON USER NAME SPACE */
-# elif defined _AIX
-# define YYSTACK_ALLOC __alloca
-# elif defined _MSC_VER
-# include /* INFRINGES ON USER NAME SPACE */
-# define alloca _alloca
-# else
-# define YYSTACK_ALLOC alloca
-# if ! defined _ALLOCA_H && ! defined EXIT_SUCCESS
-# include /* INFRINGES ON USER NAME SPACE */
- /* Use EXIT_SUCCESS as a witness for stdlib.h. */
-# ifndef EXIT_SUCCESS
-# define EXIT_SUCCESS 0
-# endif
-# endif
-# endif
-# endif
-# endif
-
-# ifdef YYSTACK_ALLOC
- /* Pacify GCC's 'empty if-body' warning. */
-# define YYSTACK_FREE(Ptr) do { /* empty */; } while (0)
-# ifndef YYSTACK_ALLOC_MAXIMUM
- /* The OS might guarantee only one guard page at the bottom of the stack,
- and a page size can be as small as 4096 bytes. So we cannot safely
- invoke alloca (N) if N exceeds 4096. Use a slightly smaller number
- to allow for a few compiler-allocated temporary stack slots. */
-# define YYSTACK_ALLOC_MAXIMUM 4032 /* reasonable circa 2006 */
-# endif
-# else
-# define YYSTACK_ALLOC YYMALLOC
-# define YYSTACK_FREE YYFREE
-# ifndef YYSTACK_ALLOC_MAXIMUM
-# define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM
-# endif
-# if (defined __cplusplus && ! defined EXIT_SUCCESS \
- && ! ((defined YYMALLOC || defined malloc) \
- && (defined YYFREE || defined free)))
-# include /* INFRINGES ON USER NAME SPACE */
-# ifndef EXIT_SUCCESS
-# define EXIT_SUCCESS 0
-# endif
-# endif
-# ifndef YYMALLOC
-# define YYMALLOC malloc
-# if ! defined malloc && ! defined EXIT_SUCCESS
-void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */
-# endif
-# endif
-# ifndef YYFREE
-# define YYFREE free
-# if ! defined free && ! defined EXIT_SUCCESS
-void free (void *); /* INFRINGES ON USER NAME SPACE */
-# endif
-# endif
-# endif
-#endif /* !defined yyoverflow */
-
-#if (! defined yyoverflow \
- && (! defined __cplusplus \
- || (defined YYLTYPE_IS_TRIVIAL && YYLTYPE_IS_TRIVIAL \
- && defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL)))
-
-/* A type that is properly aligned for any stack member. */
-union yyalloc
-{
- yy_state_t yyss_alloc;
- YYSTYPE yyvs_alloc;
- YYLTYPE yyls_alloc;
-};
-
-/* The size of the maximum gap between one aligned stack and the next. */
-# define YYSTACK_GAP_MAXIMUM (YYSIZEOF (union yyalloc) - 1)
-
-/* The size of an array large to enough to hold all stacks, each with
- N elements. */
-# define YYSTACK_BYTES(N) \
- ((N) * (YYSIZEOF (yy_state_t) + YYSIZEOF (YYSTYPE) \
- + YYSIZEOF (YYLTYPE)) \
- + 2 * YYSTACK_GAP_MAXIMUM)
-
-# define YYCOPY_NEEDED 1
-
-/* Relocate STACK from its old location to the new one. The
- local variables YYSIZE and YYSTACKSIZE give the old and new number of
- elements in the stack, and YYPTR gives the new location of the
- stack. Advance YYPTR to a properly aligned location for the next
- stack. */
-# define YYSTACK_RELOCATE(Stack_alloc, Stack) \
- do \
- { \
- YYPTRDIFF_T yynewbytes; \
- YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \
- Stack = &yyptr->Stack_alloc; \
- yynewbytes = yystacksize * YYSIZEOF (*Stack) + YYSTACK_GAP_MAXIMUM; \
- yyptr += yynewbytes / YYSIZEOF (*yyptr); \
- } \
- while (0)
-
-#endif
-
-#if defined YYCOPY_NEEDED && YYCOPY_NEEDED
-/* Copy COUNT objects from SRC to DST. The source and destination do
- not overlap. */
-# ifndef YYCOPY
-# if defined __GNUC__ && 1 < __GNUC__
-# define YYCOPY(Dst, Src, Count) \
- __builtin_memcpy (Dst, Src, YY_CAST (YYSIZE_T, (Count)) * sizeof (*(Src)))
-# else
-# define YYCOPY(Dst, Src, Count) \
- do \
- { \
- YYPTRDIFF_T yyi; \
- for (yyi = 0; yyi < (Count); yyi++) \
- (Dst)[yyi] = (Src)[yyi]; \
- } \
- while (0)
-# endif
-# endif
-#endif /* !YYCOPY_NEEDED */
-
-/* YYFINAL -- State number of the termination state. */
-#define YYFINAL 109
-/* YYLAST -- Last index in YYTABLE. */
-#define YYLAST 6863
-
-/* YYNTOKENS -- Number of terminals. */
-#define YYNTOKENS 180
-/* YYNNTS -- Number of nonterminals. */
-#define YYNNTS 113
-/* YYNRULES -- Number of rules. */
-#define YYNRULES 789
-/* YYNSTATES -- Number of states. */
-#define YYNSTATES 1678
-
-/* YYMAXUTOK -- Last valid token kind. */
-#define YYMAXUTOK 410
-
-
-/* YYTRANSLATE(TOKEN-NUM) -- Symbol number corresponding to TOKEN-NUM
- as returned by yylex, with out-of-bounds checking. */
-#define YYTRANSLATE(YYX) \
- (0 <= (YYX) && (YYX) <= YYMAXUTOK \
- ? YY_CAST (yysymbol_kind_t, yytranslate[YYX]) \
- : YYSYMBOL_YYUNDEF)
-
-/* YYTRANSLATE[TOKEN-NUM] -- Symbol number corresponding to TOKEN-NUM
- as returned by yylex. */
-static const yytype_uint8 yytranslate[] =
-{
- 0, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 178, 2, 2, 2, 171, 164, 2,
- 174, 176, 169, 167, 157, 168, 173, 170, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 159, 158,
- 165, 160, 166, 161, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 175, 2, 179, 163, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 156, 162, 177, 172, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 1, 2, 3, 4,
- 5, 6, 7, 8, 9, 10, 11, 12, 13, 14,
- 15, 16, 17, 18, 19, 20, 21, 22, 23, 24,
- 25, 26, 27, 28, 29, 30, 31, 32, 33, 34,
- 35, 36, 37, 38, 39, 40, 41, 42, 43, 44,
- 45, 46, 47, 48, 49, 50, 51, 52, 53, 54,
- 55, 56, 57, 58, 59, 60, 61, 62, 63, 64,
- 65, 66, 67, 68, 69, 70, 71, 72, 73, 74,
- 75, 76, 77, 78, 79, 80, 81, 82, 83, 84,
- 85, 86, 87, 88, 89, 90, 91, 92, 93, 94,
- 95, 96, 97, 98, 99, 100, 101, 102, 103, 104,
- 105, 106, 107, 108, 109, 110, 111, 112, 113, 114,
- 115, 116, 117, 118, 119, 120, 121, 122, 123, 124,
- 125, 126, 127, 128, 129, 130, 131, 132, 133, 134,
- 135, 136, 137, 138, 139, 140, 141, 142, 143, 144,
- 145, 146, 147, 148, 149, 150, 151, 152, 153, 154,
- 155
-};
-
-#if YYDEBUG
-/* YYRLINE[YYN] -- Source line where rule number YYN was defined. */
-static const yytype_int16 yyrline[] =
-{
- 0, 466, 466, 467, 471, 478, 479, 486, 485, 496,
- 497, 501, 505, 509, 522, 521, 533, 534, 535, 536,
- 537, 538, 539, 552, 561, 565, 573, 577, 581, 602,
- 629, 650, 679, 715, 758, 770, 791, 827, 861, 883,
- 919, 941, 952, 966, 965, 980, 984, 989, 993, 1004,
- 1008, 1012, 1016, 1020, 1029, 1033, 1037, 1041, 1045, 1049,
- 1053, 1057, 1061, 1068, 1072, 1077, 1085, 1090, 1098, 1102,
- 1110, 1115, 1124, 1123, 1139, 1149, 1148, 1165, 1173, 1181,
- 1193, 1210, 1209, 1224, 1239, 1249, 1265, 1264, 1307, 1306,
- 1335, 1334, 1372, 1371, 1403, 1402, 1422, 1421, 1443, 1442,
- 1475, 1474, 1501, 1514, 1518, 1522, 1526, 1530, 1539, 1543,
- 1547, 1551, 1555, 1560, 1565, 1569, 1573, 1580, 1584, 1588,
- 1592, 1596, 1600, 1604, 1608, 1612, 1616, 1620, 1624, 1628,
- 1632, 1636, 1640, 1644, 1648, 1652, 1656, 1660, 1664, 1668,
- 1672, 1676, 1680, 1684, 1688, 1692, 1696, 1700, 1704, 1708,
- 1712, 1716, 1720, 1724, 1728, 1732, 1736, 1743, 1744, 1745,
- 1749, 1751, 1750, 1758, 1759, 1763, 1764, 1768, 1774, 1783,
- 1784, 1788, 1792, 1796, 1800, 1806, 1812, 1818, 1825, 1830,
- 1836, 1843, 1852, 1856, 1861, 1869, 1881, 1885, 1899, 1914,
- 1919, 1924, 1929, 1934, 1939, 1944, 1949, 1955, 1954, 1985,
- 1995, 2005, 2009, 2013, 2022, 2026, 2034, 2038, 2043, 2047,
- 2052, 2060, 2065, 2073, 2077, 2082, 2086, 2091, 2099, 2104,
- 2112, 2116, 2123, 2127, 2134, 2138, 2142, 2146, 2150, 2157,
- 2161, 2165, 2169, 2173, 2177, 2184, 2185, 2186, 2190, 2193,
- 2194, 2195, 2199, 2211, 2230, 2234, 2244, 2248, 2252, 2257,
- 2262, 2267, 2272, 2277, 2282, 2287, 2295, 2299, 2303, 2308,
- 2313, 2318, 2323, 2328, 2333, 2338, 2343, 2349, 2357, 2362,
- 2367, 2372, 2377, 2382, 2387, 2392, 2397, 2402, 2407, 2413,
- 2421, 2425, 2430, 2435, 2440, 2445, 2450, 2455, 2460, 2465,
- 2470, 2478, 2482, 2487, 2492, 2497, 2502, 2507, 2512, 2517,
- 2522, 2527, 2532, 2538, 2545, 2552, 2562, 2566, 2574, 2578,
- 2582, 2586, 2590, 2606, 2622, 2631, 2635, 2645, 2649, 2656,
- 2667, 2671, 2679, 2683, 2687, 2691, 2695, 2711, 2727, 2745,
- 2754, 2758, 2768, 2772, 2779, 2783, 2791, 2795, 2811, 2827,
- 2836, 2846, 2850, 2857, 2861, 2869, 2873, 2878, 2882, 2891,
- 2890, 2915, 2914, 2944, 2945, 2952, 2953, 2957, 2958, 2962,
- 2966, 2970, 2974, 2978, 2982, 2986, 2990, 2994, 2998, 3006,
- 3005, 3022, 3026, 3030, 3035, 3043, 3047, 3054, 3055, 3060,
- 3067, 3068, 3073, 3081, 3085, 3089, 3096, 3100, 3104, 3112,
- 3111, 3134, 3133, 3156, 3157, 3161, 3167, 3174, 3180, 3189,
- 3190, 3191, 3195, 3199, 3203, 3207, 3211, 3215, 3219, 3224,
- 3229, 3234, 3239, 3243, 3248, 3257, 3262, 3270, 3274, 3278,
- 3286, 3296, 3296, 3306, 3307, 3311, 3312, 3313, 3314, 3315,
- 3316, 3317, 3318, 3319, 3320, 3321, 3322, 3322, 3322, 3323,
- 3323, 3323, 3323, 3323, 3324, 3324, 3324, 3324, 3324, 3325,
- 3325, 3325, 3326, 3326, 3326, 3326, 3326, 3327, 3327, 3327,
- 3327, 3327, 3328, 3328, 3329, 3329, 3329, 3329, 3329, 3330,
- 3330, 3330, 3330, 3330, 3330, 3331, 3331, 3331, 3331, 3331,
- 3332, 3332, 3332, 3332, 3332, 3333, 3333, 3333, 3333, 3333,
- 3334, 3334, 3334, 3334, 3334, 3335, 3335, 3335, 3335, 3335,
- 3335, 3336, 3336, 3336, 3336, 3336, 3337, 3337, 3337, 3337,
- 3338, 3338, 3338, 3338, 3339, 3339, 3339, 3339, 3339, 3339,
- 3340, 3340, 3340, 3340, 3341, 3341, 3341, 3341, 3341, 3342,
- 3342, 3342, 3342, 3343, 3343, 3343, 3343, 3343, 3344, 3344,
- 3347, 3347, 3347, 3347, 3347, 3347, 3347, 3347, 3347, 3347,
- 3347, 3348, 3348, 3348, 3348, 3348, 3348, 3348, 3348, 3348,
- 3348, 3349, 3349, 3353, 3357, 3364, 3368, 3375, 3379, 3386,
- 3390, 3394, 3398, 3402, 3406, 3410, 3414, 3418, 3422, 3426,
- 3430, 3434, 3438, 3442, 3446, 3450, 3454, 3458, 3462, 3466,
- 3470, 3474, 3478, 3482, 3486, 3490, 3494, 3498, 3502, 3506,
- 3510, 3514, 3518, 3522, 3526, 3530, 3534, 3538, 3542, 3550,
- 3554, 3558, 3562, 3566, 3570, 3574, 3584, 3594, 3600, 3606,
- 3612, 3618, 3624, 3630, 3636, 3643, 3650, 3657, 3664, 3670,
- 3676, 3680, 3684, 3688, 3692, 3696, 3700, 3711, 3722, 3726,
- 3730, 3734, 3738, 3742, 3746, 3750, 3754, 3758, 3762, 3766,
- 3770, 3774, 3778, 3782, 3786, 3790, 3794, 3798, 3802, 3806,
- 3810, 3814, 3818, 3822, 3826, 3830, 3834, 3838, 3842, 3846,
- 3850, 3857, 3861, 3865, 3869, 3873, 3877, 3881, 3885, 3889,
- 3895, 3901, 3905, 3912, 3920, 3924, 3928, 3932, 3936, 3940,
- 3944, 3948, 3952, 3956, 3960, 3964, 3968, 3972, 3976, 3980,
- 3984, 3988, 4002, 4006, 4010, 4014, 4018, 4022, 4026, 4030,
- 4034, 4038, 4042, 4046, 4050, 4061, 4072, 4076, 4080, 4084,
- 4088, 4092, 4096, 4100, 4104, 4108, 4112, 4116, 4120, 4124,
- 4128, 4132, 4136, 4140, 4144, 4148, 4152, 4156, 4160, 4164,
- 4168, 4172, 4176, 4180, 4184, 4188, 4192, 4199, 4203, 4207,
- 4211, 4215, 4219, 4223, 4227, 4231, 4237, 4243, 4251, 4255,
- 4259, 4263, 4270, 4280, 4286, 4292, 4302, 4314, 4322, 4326,
- 4356, 4360, 4364, 4368, 4372, 4376, 4382, 4386, 4390, 4394,
- 4398, 4409, 4413, 4417, 4421, 4429, 4433, 4437, 4443, 4454
-};
-#endif
-
-/** Accessing symbol of state STATE. */
-#define YY_ACCESSING_SYMBOL(State) YY_CAST (yysymbol_kind_t, yystos[State])
-
-#if YYDEBUG || 0
-/* The user-facing name of the symbol whose (internal) number is
- YYSYMBOL. No bounds checking. */
-static const char *yysymbol_name (yysymbol_kind_t yysymbol) YY_ATTRIBUTE_UNUSED;
-
-/* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM.
- First, the terminals, then, starting at YYNTOKENS, nonterminals. */
-static const char *const yytname[] =
-{
- "\"end of file\"", "error", "\"invalid token\"", "REAL", "INTEGER",
- "CHAR_TOK", "SIMPLE_STRING", "SIMPLE_IDENTIFIER", "STRING_LITERAL",
- "CUSTOM_LITERAL", "IDENTIFIER", "TYPENAME_IDENTIFIER",
- "TYPEPACK_IDENTIFIER", "SCOPING", "TYPEDEFNAME", "ELLIPSIS", "OROR",
- "ANDAND", "EQCOMPARE", "NECOMPARE", "LECOMPARE", "GECOMPARE",
- "SPACESHIP", "LSHIFT", "RSHIFT", "POINTSAT_STAR", "DOT_STAR", "UNARY",
- "UNARY_NOT", "UNARY_NEGATE", "UNARY_MINUS", "UNARY_PLUS", "UNARY_STAR",
- "UNARY_REF", "POINTSAT", "SCOPE", "PLUSPLUS", "MINUSMINUS", "TIMESEQUAL",
- "DIVIDEEQUAL", "MODEQUAL", "PLUSEQUAL", "MINUSEQUAL", "OREQUAL",
- "ANDEQUAL", "XOREQUAL", "LSHIFTEQUAL", "RSHIFTEQUAL", "ATTR_LEFT",
- "ATTR_RIGHT", "KW_ALIGNAS", "KW_ALIGNOF", "KW_AUTO", "KW_BEGIN_PUBLISH",
- "KW_BLOCKING", "KW_BOOL", "KW_BUILTIN_VA_LIST", "KW_CATCH", "KW_CHAR",
- "KW_CHAR8_T", "KW_CHAR16_T", "KW_CHAR32_T", "KW_CLASS", "KW_CONST",
- "KW_CONSTEVAL", "KW_CONSTEXPR", "KW_CONSTINIT", "KW_CONST_CAST",
- "KW_DECLTYPE", "KW_DEFAULT", "KW_DELETE", "KW_DOUBLE", "KW_DYNAMIC_CAST",
- "KW_ELSE", "KW_END_PUBLISH", "KW_ENUM", "KW_EXTENSION", "KW_EXTERN",
- "KW_EXPLICIT", "KW_EXPLICIT_LPAREN", "KW_PUBLISHED", "KW_FALSE",
- "KW_FINAL", "KW_FLOAT", "KW_FRIEND", "KW_FOR", "KW_GOTO",
- "KW_HAS_VIRTUAL_DESTRUCTOR", "KW_IF", "KW_INLINE", "KW_INT",
- "KW_IS_ABSTRACT", "KW_IS_BASE_OF", "KW_IS_CLASS", "KW_IS_CONSTRUCTIBLE",
- "KW_IS_CONVERTIBLE_TO", "KW_IS_DESTRUCTIBLE", "KW_IS_EMPTY",
- "KW_IS_ENUM", "KW_IS_FINAL", "KW_IS_FUNDAMENTAL", "KW_IS_POD",
- "KW_IS_POLYMORPHIC", "KW_IS_STANDARD_LAYOUT", "KW_IS_TRIVIAL",
- "KW_IS_TRIVIALLY_COPYABLE", "KW_IS_UNION", "KW_LONG",
- "KW_MAKE_MAP_KEYS_SEQ", "KW_MAKE_MAP_PROPERTY", "KW_MAKE_PROPERTY",
- "KW_MAKE_PROPERTY2", "KW_MAKE_SEQ", "KW_MAKE_SEQ_PROPERTY", "KW_MUTABLE",
- "KW_NAMESPACE", "KW_NEW", "KW_NOEXCEPT", "KW_NOEXCEPT_LPAREN",
- "KW_NULLPTR", "KW_OPERATOR", "KW_OVERRIDE", "KW_PRIVATE", "KW_PROTECTED",
- "KW_PUBLIC", "KW_REGISTER", "KW_REINTERPRET_CAST", "KW_RESTRICT",
- "KW_RETURN", "KW_SHORT", "KW_SIGNED", "KW_SIZEOF", "KW_STATIC",
- "KW_STATIC_ASSERT", "KW_STATIC_CAST", "KW_STRUCT", "KW_TEMPLATE",
- "KW_THREAD_LOCAL", "KW_THROW", "KW_TRUE", "KW_TRY", "KW_TYPEDEF",
- "KW_TYPEID", "KW_TYPENAME", "KW_UNDERLYING_TYPE", "KW_UNION",
- "KW_UNSIGNED", "KW_USING", "KW_VIRTUAL", "KW_VOID", "KW_VOLATILE",
- "KW_WCHAR_T", "KW_WHILE", "START_CPP", "START_CONST_EXPR", "START_TYPE",
- "'{'", "','", "';'", "':'", "'='", "'?'", "'|'", "'^'", "'&'", "'<'",
- "'>'", "'+'", "'-'", "'*'", "'/'", "'%'", "'~'", "'.'", "'('", "'['",
- "')'", "'}'", "'!'", "']'", "$accept", "grammar", "cpp", "$@1",
- "constructor_inits", "constructor_init", "extern_c", "$@2",
- "declaration", "friend_declaration", "$@3", "storage_class",
- "optional_attributes", "attribute_specifiers", "attribute_specifier",
- "type_like_declaration", "$@4", "$@5", "multiple_instance_identifiers",
- "typedef_declaration", "$@6", "typedef_instance_identifiers",
- "constructor_prototype", "$@7", "$@8", "$@9", "function_prototype",
- "$@10", "$@11", "$@12", "$@13", "$@14", "function_post",
- "function_operator", "more_template_declaration", "template_declaration",
- "$@15", "template_formal_parameters",
- "template_nonempty_formal_parameters", "typename_keyword",
- "template_formal_parameter", "template_formal_parameter_type",
- "instance_identifier", "$@16",
- "instance_identifier_and_maybe_trailing_return_type",
- "maybe_trailing_return_type", "maybe_comma_identifier",
- "function_parameter_list", "function_parameters",
- "formal_parameter_list", "formal_parameters",
- "template_parameter_maybe_initialize", "maybe_initialize",
- "maybe_initialize_or_constructor_body",
- "maybe_initialize_or_function_body", "structure_init",
- "structure_init_body", "function_parameter", "formal_parameter",
- "not_paren_formal_parameter_identifier", "formal_parameter_identifier",
- "parameter_pack_identifier", "not_paren_empty_instance_identifier",
- "empty_instance_identifier", "type", "type_pack", "type_decl",
- "predefined_type", "var_type_decl", "full_type", "anonymous_struct",
- "$@17", "named_struct", "$@18", "maybe_final", "maybe_class_derivation",
- "class_derivation", "base_specification", "enum", "$@19", "enum_decl",
- "enum_element_type", "enum_body_trailing_comma", "enum_body",
- "enum_keyword", "struct_keyword", "namespace_declaration", "$@20",
- "$@21", "using_declaration", "simple_type", "simple_int_type",
- "simple_float_type", "simple_void_type", "code", "$@22", "code_block",
- "element", "optional_const_expr", "optional_const_expr_comma",
- "const_expr_comma", "no_angle_bracket_const_expr", "const_expr",
- "const_operand", "formal_const_expr", "formal_const_operand",
- "capture_list", "capture", "class_derivation_name", "name",
- "name_no_final", "string_literal", "empty", YY_NULLPTR
-};
-
-static const char *
-yysymbol_name (yysymbol_kind_t yysymbol)
-{
- return yytname[yysymbol];
-}
-#endif
-
-#define YYPACT_NINF (-1062)
-
-#define yypact_value_is_default(Yyn) \
- ((Yyn) == YYPACT_NINF)
-
-#define YYTABLE_NINF (-785)
-
-#define yytable_value_is_error(Yyn) \
- 0
-
-/* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
- STATE-NUM. */
-static const yytype_int16 yypact[] =
-{
- 188, -1062, 4339, 6032, 93, 349, -1062, -1062, -1062, -1062,
- -1062, -1062, -1062, -1062, 81, -70, -59, -43, -23, -2,
- 24, 44, 60, 91, -1062, -1062, 92, 100, 109, 143,
- 146, 154, 177, 180, 192, 200, 243, 251, 255, 264,
- 272, 275, 279, 283, 290, 317, 6228, 4339, -1062, -1062,
- 216, 324, 346, 3187, 221, -1062, 351, 368, 387, 4339,
- 4339, 4339, 4339, 4339, 2888, 581, 4339, 4754, -1062, 119,
- -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062,
- 6097, 389, -1062, 6, -1062, -1062, 1578, 2508, 2508, -1062,
- 5064, 414, -1062, 2508, -1062, -1062, 833, 833, -1062, -1062,
- -1062, -1062, -1062, 223, 223, -1062, -1062, -1062, -1062, -1062,
- 2565, 416, 274, -1062, 4339, 4339, 6032, 4339, 4339, 4339,
- 4339, 4339, 6032, 4339, 6032, 4339, 6032, 4339, 6032, 6032,
- 6032, 6032, 6032, 6032, 6032, 6032, 6032, 6032, 6032, 6032,
- 6032, 6032, 6032, 6032, 4339, -1062, -1062, -1062, 421, 5064,
- 423, 433, 223, 223, -1062, 5284, 6032, 4339, 4339, 453,
- 2888, 68, 6032, 2888, 4339, 4339, 68, 68, 68, 68,
- 68, 81, -59, -43, -23, -2, 24, 60, 92, 109,
- 5288, 6413, 6437, 6513, 387, 376, -36, 4754, -1062, -1062,
- -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062,
- 5064, 5064, -104, 397, -1062, -1062, 68, 4339, 4339, 4339,
- 4339, 4339, 4339, 4339, 4339, 4339, 4339, 4339, 4339, 4339,
- 4339, 4339, 4339, 4339, 4339, 4339, 4339, 4339, 5064, 3331,
- 4339, -1062, -1062, 833, 833, 3475, -1062, -1062, -1062, 2508,
- -1062, -1062, -1062, -1062, 6032, -1062, 432, 564, 223, 833,
- 833, 833, 223, 223, 59, 462, -1062, 463, -1062, 473,
- 87, 2050, 5064, 583, 487, 474, 3037, -1062, 6616, 465,
- 500, -1062, 494, 496, 506, 511, 516, 525, 528, 483,
- 530, 495, 531, 532, 533, 534, 536, 543, -15, 563,
- 551, 556, 562, 566, 567, 568, 572, 573, 576, 582,
- 584, 587, 4339, -1062, 6032, 4339, 5064, 5064, -1062, 546,
- 589, 590, 5064, 592, 574, 593, 5303, 596, 597, 4339,
- 4339, -1062, 732, -1062, 1631, 600, 4339, -1062, -1062, 1881,
- 4935, 5120, 5120, 555, 555, 485, 298, 298, -1062, 3642,
- 5661, 1606, 1809, 555, 555, 132, 132, 68, 68, 68,
- -1062, -1062, 28, 2457, -1062, -1062, 604, 5345, 613, 223,
- 223, 1104, 462, -1062, 462, -1062, 462, -1062, 1104, 1104,
- -1062, 223, 223, 223, 6713, 621, 30, -1062, 622, 4339,
- -1062, -1062, -1062, -1062, -1062, 2131, 634, 3, 41, 57,
- 106, -1062, -1062, -1062, 640, 223, 5064, 2062, 81, -1062,
- -1062, 628, 5064, 632, 638, -1062, -1062, -1062, 223, 223,
- -1062, 5366, -1062, 6713, 6713, 6713, 6713, 6713, -1062, 6713,
- 5814, 6713, 4339, 656, -1062, 6656, 644, 645, 646, 647,
- 648, 649, 6713, 62, 667, 669, 673, 6713, 6713, 660,
- 6551, 6713, 6713, 4685, 6713, 6713, -1062, -1062, -1062, 2526,
- -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062,
- -1062, -1062, -1062, 663, -1062, 664, -1062, -1062, -1062, -1062,
- 6032, -1062, 6032, -1062, 6032, -1062, -1062, -1062, -1062, -1062,
- -1062, -1062, -1062, -1062, -1062, -1062, -1062, 5385, 665, 671,
- -1062, -1062, 666, -1062, -1062, 675, 4483, 678, -1062, -1062,
- -1062, -1062, 68, 4754, -1062, 5064, 397, 55, 5806, -1062,
- 4754, 4339, -1062, -1062, -1062, -1062, -1062, 1104, 668, 670,
- 5064, 223, 1104, 1104, 1104, 223, 223, 674, -1062, 674,
- 674, 1104, 1104, 1104, 5889, 6713, 6097, -1062, -1062, 117,
- 679, 4754, -1062, 5064, 676, -1062, -1062, -1062, -1062, 2131,
- -1062, 763, 5064, -1062, -1062, -1062, -1062, -1062, -1062, -1062,
- -1062, 686, 697, 701, -1062, -1062, 6228, -1062, -1062, 702,
- 4880, 710, -1062, 695, 4339, 4339, 4339, 4339, 2888, 4339,
- 700, 42, -1062, -1062, 5644, -1062, 119, 703, 3619, -1062,
- 6032, 223, 2581, 2050, 223, -1062, -1062, -1062, -1062, -1062,
- -1062, 6713, -1062, -1062, -1062, 5404, -1062, 6616, 3389, -1062,
- 5064, 5064, 5064, 5064, 5064, 5064, -1062, -1062, 5064, -1062,
- -1062, -1062, -1062, -1062, 4339, -1062, 5109, -1062, 712, -1062,
- 5209, -1062, 5064, 5064, 2, -1062, -1062, 457, 706, 6130,
- -1062, 5064, -1062, 224, 723, -1062, 4339, 4339, 709, 711,
- 713, -1062, -1062, -1062, 4339, -1062, 4339, -1062, 715, -1062,
- -1062, -1062, -1062, -1062, -1062, 4339, -1062, 708, -1062, -1062,
- 852, 4754, 674, 223, 223, 1104, 674, 674, 674, 1104,
- 1104, 4339, -103, 85, 133, 977, 946, 5806, -1062, -1062,
- 223, 223, -1062, 736, 58, -1062, 729, -1062, 844, 6032,
- 6032, 6032, 721, 6032, 725, 2888, 95, 6032, 2888, 68,
- 68, 68, 68, 726, 101, 68, -1062, -1062, 4863, 4339,
- 4339, 4339, 4339, 4339, 4339, 4339, 4339, 4339, 4339, 4339,
- 4339, 4339, 4339, 4339, 4339, 4339, 4339, 4339, 4339, 4339,
- 5064, 3763, 4339, 727, 5464, 731, -1062, -1062, 746, -1062,
- -1062, -1062, 6713, -1062, -1062, 753, 757, 759, 760, 764,
- 769, 770, 80, 772, 4506, 5921, 395, 755, 224, -1062,
- -1062, 773, 774, -1062, 775, -1062, 22, 6293, 1248, -1062,
- 756, 517, -1062, -1062, 2204, -1062, -1062, 704, 124, 183,
- -1062, -1062, -1062, 189, 196, -1062, 5565, 365, 6195, 777,
- -1062, 1104, -1062, 674, 674, 674, 762, 778, 784, 788,
- 765, 223, 977, 977, 977, 223, 223, 977, -81, 223,
- -1062, 767, 5064, 223, 946, 946, 946, 223, 223, 946,
- 8, 852, 771, 36, -1062, 6311, 791, 794, -1062, 223,
- 790, 782, 798, 4339, 801, 5064, 792, 809, 800, 5584,
- 4339, -1062, -1062, -1062, 1881, 4935, 5120, 5120, 555, 555,
- 485, 298, 298, -1062, 3930, 5661, 1606, 1809, 555, 555,
- 132, 132, 68, 68, 68, -1062, -1062, 207, 2907, -1062,
- -1062, -1062, 2131, -1062, 98, -1062, 969, 971, 972, 974,
- 975, 976, -1062, -1062, 427, 835, -1062, -1062, -1062, -1062,
- 5975, -1062, 5975, 825, 838, 6470, -1062, 744, -1062, -1062,
- 20, -1062, 704, -1062, -1062, 6032, 55, 820, 829, 704,
- 55, 1248, 830, 223, 1248, 1248, 1248, 223, 223, 56,
- 223, -1062, 99, -1062, -1062, -1062, 5064, 405, -1062, 826,
- -1062, 848, 850, 3907, 4214, 842, 223, 704, 5043, 704,
- 223, 223, 704, -1062, 77, 454, 223, -1062, -1062, -1062,
- -1062, 5806, -1062, -1062, 14, 6228, 833, -1062, 674, 223,
- 55, 55, 55, 223, 977, 837, 837, 837, 977, 977,
- 328, 4339, -1062, -1062, 223, 223, 946, 840, 840, 840,
- 946, 946, 336, 4339, -1062, -1062, -1062, 4339, 6378, 6393,
- 6408, 5064, 498, -1062, -1062, 998, -1062, 6311, -1062, -1062,
- 843, 849, 846, 854, 856, 4483, 865, -1062, -1062, 68,
- 4339, -1062, -1062, 736, -1062, -1062, 861, 212, 873, 884,
- 889, 895, -1062, 43, -1062, 744, 744, 6696, 5921, 5064,
- 885, 897, 223, 744, 744, 744, 223, 223, 744, 65,
- 840, -1062, 454, 910, 893, 898, 704, 492, 899, 410,
- 223, 1248, 901, 901, 901, 1248, 1248, -1062, 4339, -1062,
- -1062, 55, 900, 468, -1062, 89, 916, 920, -1062, 2711,
- -1062, -1062, -1062, 3907, 902, 923, 4754, -1062, -1062, 223,
- 704, 460, 1071, -1062, -1062, -1062, -1062, -1062, -1062, -1062,
- -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062,
- -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062,
- -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062,
- 909, 907, -1062, 223, 460, 704, 704, 515, 4339, -1062,
- 4339, -1062, 2204, 931, -1062, -1062, 852, 913, -1062, 833,
- -1062, 914, -1062, 917, 919, 924, 977, 837, 837, 837,
- 918, 911, 946, -1062, 840, 840, 840, 925, 922, 5625,
- 1336, -1062, 1336, -1062, 1336, -1062, -1062, 1336, 1336, 1336,
- -1062, 102, -1062, 4339, 4339, -1062, 4339, -1062, 4339, 4754,
- 134, 1092, 1093, 948, 1097, 932, -1062, 1099, 1106, 1108,
- 157, 956, 65, 840, 65, 840, -1062, -1062, -1062, -1062,
- -1062, -1062, 6032, 223, 744, 744, 744, 1788, -1062, -1062,
- 965, -1062, -1062, -1062, -1062, 523, 951, -1062, -1062, 1248,
- 901, 901, 901, 55, 952, 958, -1062, -1062, 5064, 4339,
- 4339, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062,
- -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062,
- -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062,
- -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062,
- -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062,
- -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062,
- -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062,
- -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062,
- -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062,
- -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062,
- -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062,
- -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062,
- -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062,
- -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062,
- -1062, -1062, 955, -1062, 4051, 704, 460, 223, -1062, -1062,
- -1062, 460, 460, -1062, 4754, 2062, 964, 4214, 704, 979,
- -1062, -1062, -1062, -1062, -1062, -1062, 837, 55, 223, 840,
- 55, 223, -1062, -1062, -1062, -1062, -1062, -1062, -1062, -1062,
- 230, 252, 254, 266, -1062, 968, 304, -1062, 990, 991,
- 325, 982, 339, -1062, -1062, -1062, -1062, -1062, 744, 978,
- 985, 988, 994, 4627, 997, 1788, 1788, 1788, 1788, 1788,
- 2888, 1788, 1343, -1062, 704, 5806, 55, 989, -1062, 5806,
- 55, 901, 992, 223, -1062, 987, -1062, 993, 996, 2382,
- -1062, 3907, 4754, 460, -1062, 999, 223, -1062, -1062, 5806,
- 5806, 5806, 1000, -1062, 1001, -1062, -1062, -1062, -1062, -1062,
- 1011, 1163, 1016, 1168, -1062, 1170, 1023, 1024, 1174, 1027,
- 6032, 6032, 6032, 6032, 1012, 2888, 152, 6032, 152, 152,
- 152, 152, 152, 1013, 367, 152, 1788, 1788, 1788, 1788,
- 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788,
- 1788, 1788, 1788, 1788, 1788, 5064, 4195, 4339, -1062, -1062,
- 1014, -1062, 55, -1062, 1015, -1062, -1062, 5806, -1062, -1062,
- 1172, -1062, 1019, -1062, -1062, 1021, 852, 852, 852, -1062,
- -1062, -1062, 1036, -1062, 1026, 1042, -1062, -1062, 369, -1062,
- 1028, 1034, 1039, 1041, 5064, 1032, 1043, 1788, -1062, 1911,
- 4954, 1257, 1257, 888, 888, 1441, 617, 617, -1062, 1363,
- 5678, 5743, 4478, 281, 281, 152, 152, 152, -1062, -1062,
- 370, 3205, -1062, 55, 1035, -1062, 3534, -1062, -1062, -1062,
- 5806, -1062, -1062, -1062, -1062, 5806, 5806, 1200, 1040, 1054,
- 1208, 1209, 1062, -1062, 1047, 1049, 1050, 1051, 4731, 1055,
- 152, 1788, -1062, -1062, 5806, 1057, -1062, 3534, -1062, -1062,
- -1062, -1062, 1067, -1062, 1058, 371, -1062, 4339, 4339, 4339,
- -1062, 4339, 1343, -1062, -1062, 5806, -1062, 1072, 1225, 1078,
- 372, 378, 380, 383, 5806, 852, -1062, 1064, -1062, -1062,
- -1062, -1062, -1062, 852, -1062, 1083, -1062, -1062
-};
-
-/* YYDEFACT[STATE-NUM] -- Default reduction number in state STATE-NUM.
- Performed when YYTABLE does not specify something else to do. Zero
- means the default is an error. */
-static const yytype_int16 yydefact[] =
-{
- 0, 789, 0, 0, 0, 789, 5, 675, 671, 674,
- 785, 786, 677, 678, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 673, 679, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 681, 680,
- 0, 0, 0, 0, 0, 672, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 789, 0, 3, 609, 676,
- 307, 319, 317, 402, 318, 403, 405, 406, 407, 386,
- 0, 0, 418, 383, 417, 412, 409, 408, 411, 387,
- 0, 0, 388, 410, 420, 404, 789, 789, 4, 309,
- 310, 311, 369, 789, 789, 306, 399, 400, 401, 1,
- 0, 0, 7, 63, 789, 789, 0, 789, 789, 789,
- 789, 789, 0, 789, 0, 789, 0, 789, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 789, 335, 341, 342, 0, 0,
- 0, 634, 789, 789, 334, 0, 0, 789, 789, 0,
- 0, 631, 0, 0, 789, 789, 643, 641, 640, 642,
- 639, 307, 402, 403, 405, 406, 407, 418, 417, 412,
- 409, 408, 411, 410, 404, 0, 0, 567, 770, 771,
- 772, 780, 773, 776, 774, 778, 777, 775, 779, 759,
- 760, 0, 0, 789, 765, 758, 638, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 787, 788, 789, 789, 0, 384, 385, 419, 409,
- 414, 413, 416, 308, 0, 415, 0, 292, 789, 789,
- 789, 789, 789, 789, 789, 0, 345, 291, 347, 0,
- 372, 0, 0, 0, 68, 70, 0, 6, 789, 0,
- 566, 565, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 336, 0, 789, 0, 0, 667, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 670, 763, 766, 0, 789, 0, 761, 222, 652,
- 653, 654, 655, 656, 657, 658, 661, 662, 669, 0,
- 649, 650, 651, 659, 660, 647, 648, 644, 645, 646,
- 668, 666, 0, 0, 346, 348, 0, 0, 0, 789,
- 789, 789, 0, 294, 0, 296, 0, 295, 789, 789,
- 207, 789, 789, 789, 789, 0, 208, 211, 63, 789,
- 789, 781, 782, 783, 784, 0, 374, 770, 771, 772,
- 774, 349, 312, 351, 0, 789, 0, 789, 321, 332,
- 333, 0, 0, 0, 0, 323, 324, 325, 789, 789,
- 320, 0, 22, 789, 789, 789, 789, 789, 23, 789,
- 789, 789, 0, 0, 43, 789, 0, 0, 0, 0,
- 0, 0, 789, 789, 0, 0, 0, 789, 789, 0,
- 789, 789, 789, 0, 789, 789, 18, 8, 20, 0,
- 16, 17, 19, 78, 45, 616, 615, 633, 623, 618,
- 620, 621, 622, 0, 629, 0, 628, 684, 617, 685,
- 0, 687, 0, 688, 0, 691, 692, 693, 694, 695,
- 696, 697, 698, 699, 700, 701, 625, 0, 0, 0,
- 338, 337, 0, 624, 627, 0, 630, 0, 636, 637,
- 626, 619, 610, 568, 764, 0, 789, 789, 789, 103,
- 223, 0, 665, 664, 315, 314, 316, 789, 293, 0,
- 281, 789, 789, 789, 789, 789, 789, 299, 280, 298,
- 297, 789, 789, 789, 789, 789, 0, 789, 210, 789,
- 0, 564, 563, 380, 0, 377, 376, 371, 375, 0,
- 789, 789, 0, 64, 69, 751, 747, 750, 753, 754,
- 214, 0, 0, 0, 749, 755, 0, 757, 756, 0,
- 0, 0, 748, 0, 0, 0, 0, 0, 0, 0,
- 0, 215, 244, 218, 245, 702, 752, 63, 0, 322,
- 0, 789, 372, 0, 789, 60, 46, 57, 58, 59,
- 61, 789, 47, 160, 52, 0, 24, 789, 0, 50,
- 0, 0, 0, 0, 0, 0, 56, 789, 0, 27,
- 26, 25, 54, 49, 0, 164, 0, 163, 0, 62,
- 0, 21, 0, 0, 789, 51, 55, 344, 321, 0,
- 14, 0, 75, 0, 343, 72, 0, 0, 0, 0,
- 0, 339, 340, 635, 0, 632, 0, 762, 0, 111,
- 104, 113, 108, 112, 106, 0, 109, 0, 105, 110,
- 789, 663, 300, 789, 789, 789, 283, 285, 284, 789,
- 789, 789, 0, 0, 0, 789, 0, 789, 209, 212,
- 789, 789, 370, 313, 789, 354, 789, 353, 0, 0,
- 0, 0, 712, 0, 0, 0, 709, 0, 0, 720,
- 719, 718, 717, 0, 0, 716, 71, 217, 789, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 67, 328, 374, 326,
- 66, 48, 789, 44, 789, 0, 0, 0, 0, 0,
- 0, 0, 789, 0, 0, 789, 344, 321, 0, 343,
- 81, 0, 0, 395, 0, 86, 90, 0, 789, 789,
- 0, 0, 421, 229, 0, 77, 74, 0, 0, 0,
- 686, 689, 690, 0, 0, 789, 0, 0, 0, 0,
- 201, 789, 282, 288, 287, 286, 0, 0, 0, 0,
- 0, 789, 789, 789, 789, 789, 789, 789, 789, 789,
- 256, 0, 268, 789, 0, 0, 0, 789, 789, 0,
- 789, 789, 301, 381, 350, 0, 0, 356, 355, 789,
- 0, 0, 0, 789, 0, 0, 0, 0, 0, 0,
- 0, 746, 216, 219, 729, 730, 731, 732, 733, 734,
- 735, 738, 739, 745, 0, 726, 727, 728, 736, 737,
- 724, 725, 721, 722, 723, 744, 743, 0, 0, 330,
- 329, 331, 0, 53, 789, 391, 0, 0, 0, 0,
- 0, 0, 393, 389, 0, 0, 183, 184, 185, 169,
- 0, 170, 0, 0, 166, 171, 167, 789, 182, 165,
- 0, 83, 0, 398, 397, 0, 789, 0, 0, 0,
- 789, 789, 0, 789, 789, 789, 789, 789, 789, 0,
- 789, 246, 789, 92, 421, 224, 0, 0, 76, 0,
- 789, 0, 0, 789, 0, 0, 789, 0, 0, 0,
- 789, 789, 0, 73, 789, 789, 789, 613, 612, 614,
- 611, 789, 107, 114, 0, 0, 789, 421, 289, 789,
- 789, 789, 789, 789, 789, 258, 260, 259, 789, 789,
- 0, 789, 242, 257, 789, 789, 0, 270, 272, 271,
- 0, 0, 0, 789, 243, 302, 378, 0, 778, 0,
- 777, 0, 0, 357, 359, 767, 789, 0, 65, 711,
- 0, 0, 0, 0, 0, 708, 0, 714, 715, 703,
- 0, 742, 741, 327, 394, 789, 0, 0, 789, 0,
- 0, 0, 789, 0, 42, 789, 789, 789, 0, 174,
- 172, 0, 789, 789, 789, 789, 789, 789, 789, 789,
- 178, 82, 789, 0, 0, 0, 0, 0, 0, 0,
- 789, 789, 248, 250, 249, 789, 789, 98, 789, 247,
- 15, 789, 0, 0, 9, 0, 0, 0, 230, 422,
- 423, 232, 233, 789, 0, 236, 238, 235, 231, 789,
- 0, 189, 0, 127, 128, 129, 130, 131, 132, 135,
- 136, 137, 152, 140, 141, 142, 143, 144, 145, 146,
- 147, 148, 149, 150, 151, 156, 155, 139, 138, 124,
- 126, 125, 133, 134, 122, 123, 119, 120, 121, 118,
- 0, 0, 117, 789, 190, 0, 0, 0, 0, 197,
- 789, 199, 0, 0, 79, 186, 789, 0, 115, 789,
- 202, 0, 290, 0, 0, 0, 789, 263, 262, 261,
- 267, 0, 0, 269, 275, 274, 273, 279, 0, 382,
- 0, 362, 0, 361, 0, 360, 768, 0, 0, 0,
- 769, 789, 358, 0, 0, 713, 0, 710, 0, 740,
- 789, 0, 0, 0, 0, 0, 204, 0, 0, 0,
- 789, 0, 789, 179, 789, 181, 159, 157, 162, 158,
- 168, 175, 0, 789, 789, 789, 789, 0, 176, 220,
- 0, 84, 396, 789, 88, 0, 0, 789, 100, 789,
- 253, 252, 251, 789, 0, 0, 225, 421, 0, 789,
- 789, 227, 228, 425, 426, 430, 427, 435, 428, 429,
- 431, 432, 433, 434, 436, 437, 438, 439, 440, 441,
- 442, 443, 444, 445, 446, 447, 448, 449, 450, 451,
- 452, 453, 454, 455, 456, 457, 458, 459, 460, 461,
- 462, 463, 464, 465, 466, 467, 468, 469, 470, 471,
- 472, 473, 474, 475, 476, 477, 478, 479, 480, 481,
- 482, 483, 484, 485, 486, 487, 488, 489, 511, 490,
- 491, 492, 493, 494, 495, 496, 497, 498, 499, 500,
- 501, 502, 503, 504, 505, 506, 507, 508, 509, 510,
- 512, 513, 514, 515, 516, 517, 518, 519, 520, 521,
- 522, 523, 524, 525, 526, 527, 528, 529, 530, 531,
- 532, 533, 534, 535, 536, 537, 538, 539, 789, 556,
- 557, 558, 549, 561, 545, 546, 544, 551, 552, 540,
- 541, 542, 543, 550, 548, 555, 553, 559, 554, 547,
- 560, 424, 0, 234, 237, 0, 193, 789, 154, 153,
- 187, 192, 191, 196, 200, 789, 0, 223, 0, 0,
- 116, 203, 682, 789, 789, 789, 264, 789, 789, 276,
- 789, 789, 379, 368, 367, 366, 365, 364, 363, 352,
- 0, 0, 0, 0, 392, 0, 0, 34, 205, 0,
- 0, 0, 0, 390, 41, 177, 180, 173, 789, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 221, 569, 0, 789, 789, 0, 94, 789,
- 789, 254, 0, 789, 789, 0, 10, 0, 0, 0,
- 239, 789, 240, 194, 188, 0, 789, 80, 421, 789,
- 789, 789, 0, 265, 0, 277, 706, 705, 707, 704,
- 0, 0, 0, 0, 28, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 576, 0, 584, 582,
- 581, 583, 580, 0, 0, 579, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 85, 87,
- 0, 96, 789, 91, 0, 789, 255, 789, 226, 13,
- 11, 562, 0, 789, 195, 0, 789, 789, 789, 789,
- 789, 37, 789, 35, 0, 0, 38, 40, 0, 30,
- 0, 0, 0, 0, 0, 0, 0, 0, 608, 593,
- 594, 595, 596, 597, 598, 599, 600, 601, 607, 0,
- 590, 591, 592, 588, 589, 585, 586, 587, 606, 605,
- 0, 0, 789, 789, 0, 789, 99, 93, 12, 241,
- 789, 683, 305, 304, 303, 789, 789, 0, 0, 0,
- 0, 0, 0, 578, 0, 0, 0, 0, 575, 0,
- 570, 0, 604, 603, 789, 0, 789, 101, 198, 266,
- 278, 205, 0, 29, 0, 0, 31, 0, 0, 0,
- 577, 0, 602, 89, 789, 789, 36, 0, 0, 0,
- 0, 0, 0, 0, 789, 789, 39, 0, 32, 573,
- 572, 574, 571, 789, 95, 0, 97, 33
-};
-
-/* YYPGOTO[NTERM-NUM]. */
-static const yytype_int16 yypgoto[] =
-{
- -1062, -1062, -525, -1062, -1062, 4, -1062, -1062, 636, -428,
- -1062, -354, 210, -358, -1062, -426, -1062, -1062, -153, -1062,
- -1062, -208, -1062, -1062, -1062, -1062, 620, -1062, -1062, -1062,
- -1062, -1062, -448, -1062, -1062, -414, -1062, -1062, -1062, -1062,
- 209, -412, -746, -1062, -886, -775, -311, -406, -1062, -142,
- -1062, -644, -485, -1062, -731, -1061, -1062, -381, 537, -844,
- -643, 258, -39, -96, -77, -57, -236, -539, 633, 156,
- -235, -1062, -223, -1062, -1062, -1062, -1062, 257, -222, -1062,
- -1062, -521, -1062, -1062, -27, -22, -1062, -1062, -1062, -1062,
- -28, -47, -1062, -1062, -898, -1062, -92, -1062, -623, -110,
- -60, 571, 1273, 285, 692, -1062, -1062, 943, -822, 1127,
- -116, -395, -1
-};
-
-/* YYDEFGOTO[NTERM-NUM]. */
-static const yytype_int16 yydefgoto[] =
-{
- 0, 4, 5, 268, 1073, 1074, 446, 779, 447, 448,
- 607, 449, 374, 263, 264, 450, 787, 781, 953, 631,
- 912, 1051, 642, 916, 1456, 920, 643, 1071, 1542, 1603,
- 1233, 1460, 508, 1133, 1208, 451, 628, 903, 904, 905,
- 906, 907, 954, 1395, 955, 799, 1195, 375, 376, 580,
- 581, 1218, 327, 938, 785, 1084, 1085, 377, 583, 929,
- 975, 987, 255, 256, 96, 97, 644, 151, 645, 98,
- 99, 550, 100, 551, 696, 836, 837, 1003, 101, 259,
- 102, 547, 543, 544, 103, 104, 452, 1032, 1025, 453,
- 105, 106, 107, 108, 939, 940, 1079, 1381, 540, 269,
- 270, 1630, 187, 68, 584, 585, 202, 203, 1004, 1005,
- 819, 69, 113
-};
-
-/* YYTABLE[YYPACT[STATE-NUM]] -- What to do in state STATE-NUM. If
- positive, shift that token. If negative, reduce the rule whose
- number is the opposite. If YYTABLE_NINF, syntax error. */
-static const yytype_int16 yytable[] =
-{
- 6, 258, 586, 233, 186, 272, 603, 274, 275, 276,
- 277, 278, 625, 280, 627, 282, 582, 284, 154, 152,
- 536, 657, 1382, 234, 153, 694, 1052, 702, 693, 1147,
- 404, 405, 917, 918, 301, 918, 1072, 911, 554, 240,
- 241, 242, 818, 406, 407, 538, 245, 310, 311, 231,
- 110, 232, 111, 324, 317, 318, 995, 717, 806, 595,
- 596, 597, 598, 599, 205, 600, 602, 604, 236, 1151,
- 370, 609, 681, 807, 370, 325, 371, 1059, 616, 326,
- 1062, 1063, 1064, 622, 623, -781, 626, 629, 630, 687,
- 635, 636, 762, 109, 981, 257, 257, 381, 382, 383,
- 186, 658, 216, 110, 116, 111, 110, 110, 111, 111,
- 110, 798, 111, 271, 271, 117, 271, 271, 271, 271,
- 271, 320, 271, -782, 271, 231, 271, 232, 110, 728,
- 111, 118, 688, 240, 241, 242, 245, 354, 355, -783,
- 321, 237, 472, 271, 386, 393, 110, 110, 111, 111,
- 110, 119, 111, 363, 365, 367, 271, 271, 689, -781,
- 773, 473, -781, 271, 271, 110, 216, 111, 326, 352,
- 976, 977, 120, 1057, 980, 586, 1171, 1173, 1175, 1141,
- 602, 609, 110, 993, 111, 320, 1525, 539, -784, 919,
- 1148, 919, 240, 996, 698, 489, 997, -782, 121, 718,
- -782, 1091, 328, 1134, 512, 110, 1137, 111, 384, 122,
- 362, 364, 366, -783, 405, 112, -783, 1230, 617, 1201,
- 185, 1231, 1232, 372, 1144, 1217, 406, 407, 373, 884,
- 1067, 1068, 257, 257, 123, 834, 1138, 114, 410, 408,
- 981, 228, 229, 230, 409, 1239, 385, 751, 257, 257,
- 257, 1139, 1140, 378, 932, 115, 124, 892, 320, 966,
- 681, 808, -784, 1240, 1049, -784, 125, 454, 740, 741,
- 742, 110, 273, 111, 126, 1024, 1070, 851, 279, 1419,
- 281, 320, 283, 127, 285, 286, 287, 288, 289, 290,
- 291, 292, 293, 294, 295, 296, 297, 298, 299, 300,
- 957, 225, 226, 227, 271, 228, 229, 230, 681, 809,
- 1225, 1424, 309, 260, 261, 1525, 313, 128, 314, 315,
- 129, 1221, 527, 586, 509, 1535, 1536, 1537, 130, 529,
- 530, 1157, 216, 982, 1433, 1158, 1159, 582, 548, 1465,
- 320, 1, 2, 3, 1386, 994, 320, 961, 1413, -2,
- 1414, 131, 1415, 320, 132, 1416, 1417, 1418, 1161, 958,
- 528, 1023, 306, 307, 320, 959, 133, 528, 528, 1192,
- 1168, 1399, 960, 454, 134, 188, 189, 190, 542, 545,
- 782, 156, 783, 1021, 784, 1461, 162, 320, 1193, 1391,
- 1392, 405, 1202, 1204, 769, 405, 587, 110, 883, 111,
- 358, 976, 977, 406, 407, 980, 1486, 406, 407, 320,
- 1552, 320, 454, 454, 454, 454, 454, 135, 454, 454,
- 454, 410, 408, 320, 454, 136, 1149, 409, 1487, 137,
- 1488, 454, 267, 10, 191, 11, 454, 454, 138, 454,
- 454, 454, 1489, 454, 454, 1234, 139, 192, 193, 140,
- 1532, 1533, 1534, 141, 1535, 1536, 1537, 142, 361, 685,
- 488, 1491, 368, 369, 143, 223, 224, 225, 226, 227,
- 1143, 228, 229, 230, 1076, 1077, 748, 393, 672, 686,
- 1492, 1181, 1495, 676, 677, 678, 194, 195, 1035, 196,
- 1036, 144, 682, 683, 684, 197, 1498, 198, 157, 1033,
- 1190, 1496, 548, 981, 1160, 328, 378, 1200, 214, 215,
- 1054, 993, 1167, 1406, 1058, 1499, 528, 1396, 714, 216,
- 158, 528, 528, 528, 320, 163, 1621, 320, 1658, 320,
- 528, 528, 528, 454, 454, 320, 509, 320, 154, 152,
- 320, 963, 164, 1578, 153, 1622, 1632, 1659, 1669, 6,
- 697, -102, 319, -102, 1670, -102, 1671, 326, 1435, 1672,
- 1436, 165, 778, 235, 1153, 1154, 1155, 1220, 1052, 517,
- 518, 1157, 1158, 1159, 188, 189, 190, 213, 214, 215,
- 1555, 531, 532, 533, 1228, 1068, 788, 789, 244, 216,
- 266, 188, 189, 190, 793, 302, 794, 304, 410, 408,
- 454, 359, 410, 408, 409, 553, 454, 305, 409, 1206,
- 782, 1207, 783, -102, 1142, -102, 6, -102, 592, 593,
- 1177, 1178, 1179, 1209, 1237, 1238, 648, 312, 649, 380,
- 650, 775, 395, 191, 1139, 1140, 803, 379, -280, 1473,
- 804, 805, 455, 618, 396, 714, 192, 193, 397, 463,
- 191, 1525, 223, 224, 225, 226, 227, 320, 228, 229,
- 230, 465, 930, 192, 193, 1235, 1139, 1140, 1226, 800,
- 456, 956, 457, 934, 528, 935, 936, 937, 528, 528,
- 542, 877, 458, 626, 820, 194, 195, 459, 196, 1139,
- 1140, 1393, 460, 470, 197, 838, 198, 1139, 1140, 1457,
- 921, 461, 194, 195, 462, 196, 464, 466, 467, 468,
- 469, 197, 492, 198, 381, 382, 383, 945, 670, 471,
- 474, 946, 223, 224, 225, 226, 227, 475, 228, 229,
- 230, 675, 476, 1012, 713, 679, 680, 908, 477, -281,
- 497, 199, 478, 479, 480, 200, 745, 504, 481, 482,
- 201, 454, 483, 6, 381, 382, 383, 1041, 484, 822,
- 485, 1042, 968, 486, 909, 493, 494, 947, 496, 498,
- 154, 152, 500, 501, 507, 1455, 153, 931, 6, 1459,
- 514, 1612, 1613, 1614, 1530, 1531, 1532, 1533, 1534, 516,
- 1535, 1536, 1537, 549, 509, 1406, 956, 537, -206, 552,
- 528, 746, 588, 956, 750, 930, 590, 1043, 930, 930,
- 930, 820, 820, 820, 591, 606, 820, 328, 610, 611,
- 612, 613, 614, 615, 948, 384, 619, 1462, 620, 328,
- 800, 956, 621, 956, 624, 548, 956, 646, 647, 673,
- 654, 652, 271, -282, 774, 695, 246, 653, 247, 681,
- 248, 655, 656, 692, 949, 840, 841, 842, 690, 844,
- 699, 846, 700, 847, 848, 384, 701, 703, 950, 708,
- 1150, 1044, 908, 951, 908, 707, 716, 765, 952, -213,
- 776, 786, 797, 801, 802, 790, 798, 791, 835, 792,
- 1674, 795, -373, 839, 1045, 843, 249, 831, 1676, 845,
- 832, 833, 850, 879, 112, 882, 820, 881, 1046, 885,
- 1522, 1523, 1524, 1047, 886, 378, 887, 888, 1048, 378,
- 931, 889, 1525, 931, 931, 931, 890, 891, 893, 910,
- 933, 913, 914, 967, 973, 915, 984, 154, 152, 1080,
- 956, 969, 1087, 153, 830, 930, -290, 1006, 1010, 930,
- 930, 1007, 970, 800, 328, 1479, 1480, 1481, 971, 821,
- 250, 822, 972, 823, 1011, 257, 1009, 1013, 1015, 378,
- 378, 378, 112, 820, 956, 1016, 1017, 820, 820, 1026,
- 542, 1027, 1028, 251, 1029, 1030, 1031, 381, 382, 383,
- 810, 1037, 542, 1034, 811, 1038, 1055, 252, 1056, 1060,
- 586, 1482, 253, 1078, 1484, 6, 1081, 254, 1082, 824,
- 908, 1089, 981, 1180, 582, 993, 1547, 1183, 1191, 956,
- 956, 974, 1185, 1184, 6, 978, 979, 1196, 1186, 983,
- 1194, 6, 1187, 986, 820, 820, 454, 990, 991, 1188,
- 812, 1197, 820, 820, 820, 1212, 1198, 820, 1219, 1008,
- 1540, 328, 1199, 1401, 1544, 1530, 1531, 1532, 1533, 1534,
- 931, 1535, 1536, 1537, 931, 931, 1213, 542, 1222, 1223,
- 378, 1053, 1224, 825, 1241, 1227, 1068, 1236, 1242, 1383,
- 1384, 1387, 1087, 988, 989, 1388, 1389, 992, 1398, 1400,
- 1408, 1402, 1407, 1403, 112, 1404, 826, 1606, 384, 1410,
- 1405, 1411, 1425, 1426, 813, 1610, 1427, 1428, 1429, 1430,
- 827, 1615, 1616, 930, 1434, 828, 1431, 519, 1432, 520,
- 829, 521, 1454, 1420, 1421, 1458, 1422, 814, 1423, 1467,
- 1468, 1463, 1470, 1061, 1464, 1478, 1604, 1065, 1066, 542,
- 1069, 815, 112, 1476, 1490, 800, 816, 1493, 257, 1494,
- 1501, 817, 1500, 1502, 1634, 820, 1090, 1637, 1497, 1503,
- 1135, 1136, 1507, 1541, 1548, 1050, 1145, 522, 1545, 1561,
- 1549, 1146, 1550, 1562, 1563, 1553, 1559, 1560, 1564, 1152,
- 1565, 1566, 1567, 1156, 1568, 1569, 1574, 1608, 1655, 1577,
- 1602, 1605, 204, 1617, 1162, 1163, 1609, 1635, 1611, 1620,
- 1624, 1219, 1619, 1219, 1623, 1625, 1664, 1626, 1628, 1629,
- 1641, 1636, 1643, 820, 820, 820, 1642, 243, 1644, 1645,
- 1646, 1647, 509, 1648, 1649, 1656, 509, 1650, 931, 1651,
- 1666, 523, 378, 1654, 1657, 1667, 1668, 265, 271, 271,
- 1675, 1677, 1466, 753, 1164, 1477, 1538, 1210, 1165, 1166,
- 768, 1618, 1214, 1475, 524, 853, 1215, 1216, 381, 382,
- 383, 922, 706, 770, 1182, 923, 1469, 506, 525, 956,
- 1229, 0, 0, 526, 0, 67, 303, 1520, 1521, 1522,
- 1523, 1524, 956, 0, 0, 0, 0, 0, 0, 0,
- 0, 1525, 0, 1203, 1205, 0, 0, 0, 0, 1385,
- 0, 0, 988, 989, 0, 0, 992, 0, 0, 0,
- 0, 924, 0, 0, 0, 0, 0, 0, 0, 0,
- 155, 0, 0, 0, 0, 0, 161, 322, 323, 0,
- 0, 0, 166, 167, 168, 169, 170, 0, 956, 206,
- 0, 0, 0, 1390, 0, 0, 188, 189, 190, 0,
- 0, 0, 0, 0, 0, 350, 0, 1080, 0, 1516,
- 1517, 1518, 1519, 1520, 1521, 1522, 1523, 1524, 1437, 384,
- 0, 0, 0, 0, 360, 925, 0, 1525, 0, 1516,
- 1517, 1518, 1519, 1520, 1521, 1522, 1523, 1524, 392, 394,
- 1514, 112, 0, 0, 587, 0, 0, 1525, 926, 0,
- 112, 0, 509, 509, 509, 191, 378, 0, 0, 378,
- 112, 0, 927, 0, 0, 0, 0, 928, 192, 193,
- 1409, 0, 0, 1438, 1530, 1531, 1532, 1533, 1534, 0,
- 1535, 1536, 1537, 490, 491, 0, 316, 820, 0, 495,
- 0, 0, 0, 0, 0, 1514, 0, 0, 0, 0,
- 0, 204, 0, 0, 0, 378, 0, 194, 195, 378,
- 196, 0, 0, 509, 1523, 1524, 197, 0, 198, 0,
- 1087, 0, 1164, 1165, 1166, 1525, 1600, 0, 0, 1001,
- 329, 330, 331, 332, 333, 334, 335, 336, 337, 338,
- 339, 340, 341, 342, 343, 344, 345, 346, 347, 348,
- 349, 0, 1453, 353, 1526, 1527, 1528, 1529, 357, 0,
- 1530, 1531, 1532, 1533, 1534, 0, 1535, 1536, 1537, 0,
- 0, 0, 1631, 265, 1526, 1527, 1528, 1529, 0, 589,
- 1530, 1531, 1532, 1533, 1534, 0, 1535, 1536, 1537, 411,
- 0, 378, 0, 0, 509, 0, 0, 0, 0, 0,
- 0, 0, 509, 0, 0, 800, 800, 800, 509, 509,
- 0, 1196, 0, 0, 0, 0, 0, 0, 0, 0,
- 634, 0, 0, 0, 0, 487, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 1660, 1661, 1662,
- 0, 1663, 502, 503, 0, 0, 0, 1474, 0, 510,
- 0, 509, 378, 0, 509, 0, 1513, 0, 1530, 1531,
- 1532, 1533, 1534, 0, 1535, 1536, 1537, 0, 1483, 0,
- 0, 1485, 0, 0, 209, 210, 211, 212, 213, 214,
- 215, 0, 322, 73, 0, 509, 75, 76, 77, 78,
- 216, 188, 189, 190, 0, 0, 0, 674, 0, 238,
- 0, 0, 541, 509, 0, 0, 1570, 1571, 1572, 1573,
- 0, 1575, 0, 1576, 800, 1539, 0, 0, 85, 1543,
- 691, 0, 800, 1546, 0, 0, 0, 0, 0, 265,
- 0, 0, 0, 0, 0, 239, 1554, 0, 0, 1556,
- 1557, 1558, 0, 0, 0, 605, 1409, 0, 0, 0,
- 191, 0, 0, 0, 0, 0, 0, 87, 88, 0,
- 0, 0, 0, 192, 193, 0, 0, 0, 0, 747,
- 749, 0, 0, 0, 93, 0, 0, 0, 1453, 95,
- 1453, 1453, 1453, 1453, 1453, 755, 1453, 756, 757, 758,
- 759, 760, 761, 0, 0, 763, 0, 0, 0, 0,
- 0, 0, 194, 195, 0, 196, 0, 1607, 0, 771,
- 772, 197, 0, 198, 0, 0, 0, 0, 780, 502,
- 220, 221, 222, 223, 224, 225, 226, 227, 0, 228,
- 229, 230, 0, 0, 671, 0, 0, 0, 1452, 0,
- 0, 7, 8, 9, 10, 505, 11, 12, 13, 0,
- 201, 1453, 1453, 1453, 1453, 1453, 1453, 1453, 1453, 1453,
- 1453, 1453, 1453, 1453, 1453, 1453, 1453, 1453, 1453, 1453,
- 1638, 0, 0, 0, 0, 1639, 1640, 209, 210, 211,
- 212, 213, 214, 215, 0, 0, 0, 0, 0, 1439,
- 0, 0, 0, 216, 1653, 0, 0, 709, 710, 711,
- 712, 0, 715, 0, 0, 1440, 0, 0, 0, 0,
- 1441, 744, 1453, 0, 0, 1665, 0, 875, 0, 24,
- 25, 0, 0, 0, 1673, 27, 0, 0, 0, 29,
- 30, 31, 32, 33, 34, 35, 36, 37, 38, 39,
- 40, 41, 42, 43, 44, 0, 0, 764, 208, 209,
- 210, 211, 212, 213, 214, 215, 0, 48, 0, 49,
- 0, 0, 0, 1453, 1442, 216, 1453, 0, 0, 1443,
- 0, 0, 1444, 0, 964, 0, 0, 55, 1517, 1518,
- 1519, 1520, 1521, 1522, 1523, 1524, 0, 0, 796, 0,
- 0, 0, 0, 0, 0, 1525, 0, 0, 0, 985,
- 0, 0, 1445, 0, 541, 1446, 1447, 1448, 0, 0,
- 1449, 0, 1450, 65, 0, 0, 1451, 0, 0, 0,
- 0, 0, 1014, 0, 221, 222, 223, 224, 225, 226,
- 227, 849, 228, 229, 230, 0, 0, 0, 0, 0,
- 0, 0, 854, 855, 856, 857, 858, 859, 860, 861,
- 862, 863, 864, 865, 866, 867, 868, 869, 870, 871,
- 872, 873, 874, 0, 1506, 878, 1508, 1509, 1510, 1511,
- 1512, 0, 1515, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 1040, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 218, 219, 220, 221, 222, 223, 224,
- 225, 226, 227, 0, 228, 229, 230, 944, 0, 0,
- 387, 388, 389, 1075, 0, 555, 556, 557, 10, 0,
- 11, 558, 559, 1527, 1528, 1529, 0, 560, 1530, 1531,
- 1532, 1533, 1534, 0, 1535, 1536, 1537, 1579, 1580, 1581,
- 1582, 1583, 1584, 1585, 1586, 1587, 1588, 1589, 1590, 1591,
- 1592, 1593, 1594, 1595, 1596, 1597, 0, 0, 0, 0,
- 110, 0, 111, 561, 0, 0, 0, 0, 0, 191,
- 0, 0, 0, 1019, 0, 0, 0, 0, 1176, 562,
- 0, 0, 192, 193, 563, 0, 0, 0, 0, 0,
- 0, 0, 546, 564, 565, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 1211, 0, 0, 0,
- 0, 390, 195, 0, 196, 0, 0, 0, 566, 0,
- 197, 567, 198, 568, 0, 0, 73, 0, 569, 75,
- 76, 77, 78, 570, 0, 0, 571, 0, 0, 0,
- 0, 572, 1652, 0, 573, 0, 391, 7, 8, 9,
- 10, 0, 11, 12, 13, 14, 1086, 0, 0, 0,
- 0, 85, 0, 0, 0, 0, 574, 0, 0, 575,
- 576, 0, 0, 0, 577, 0, 578, 0, 239, 0,
- 579, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 541, 15, 0, 0, 0, 16,
- 87, 88, 17, 18, 19, 20, 541, 0, 0, 0,
- 1169, 21, 0, 941, 942, 22, 23, 93, 0, 0,
- 0, 0, 95, 0, 0, 24, 25, 26, 1019, 0,
- 0, 27, 0, 1189, 28, 29, 30, 31, 32, 33,
- 34, 35, 36, 37, 38, 39, 40, 41, 42, 43,
- 44, 45, 0, 0, 0, 0, 0, 0, 0, 0,
- 46, 0, 47, 48, 0, 49, 0, 0, 0, 0,
- 50, 0, 0, 51, 52, 53, 0, 0, 54, 0,
- 0, 541, 0, 55, 0, 0, 56, 0, 0, 0,
- 57, 0, 0, 0, 0, 58, 1086, 0, 0, 0,
- 943, 0, 0, 0, 0, 1075, 0, 0, 59, 0,
- 0, 60, 61, 62, 0, 0, 63, 0, 64, 65,
- 0, 0, 66, 0, 0, 1243, 1244, 1245, 1246, 1247,
- 1248, 1249, 1250, 1251, 1252, 1253, 0, 1254, 1255, 1256,
- 1257, 1258, 1259, 1260, 1261, 1262, 1263, 1264, 1265, 0,
- 0, 1394, 0, 541, 0, 1397, 1266, 1267, 1268, 1269,
- 1270, 1271, 1272, 1273, 1274, 1275, 1276, 1277, 1278, 1279,
- 1280, 1281, 1282, 1283, 1284, 0, 0, 1285, 1286, 1287,
- 1288, 1289, 1290, 1291, 1292, 1293, 1294, 1295, 1296, 1297,
- 1298, 1299, 1300, 1301, 1302, 1303, 0, 1304, 0, 1305,
- 1306, 1307, 1308, 1309, 1310, 1311, 1312, 1313, 1314, 0,
- 1315, 1316, 1317, 207, 208, 209, 210, 211, 212, 213,
- 214, 215, 0, 0, 0, 0, 0, 0, 0, 1318,
- 0, 216, 0, 0, 0, 0, 1319, 1320, 1321, 1322,
- 1323, 1324, 1325, 1326, 1327, 1328, 1329, 1330, 1331, 1332,
- 1333, 1334, 1335, 1336, 1337, 1338, 1339, 1340, 1341, 1342,
- 1343, 1344, 1345, 1346, 1347, 1348, 1349, 1350, 1351, 1352,
- 1353, 1354, 1355, 1356, 1357, 0, 637, 638, 1358, 1359,
- 1360, 1361, 1362, 1363, 1364, 1365, 1366, 1367, 1368, 1369,
- 1370, 1371, 1372, 1373, 1374, 1375, 1376, 1377, 1378, 1551,
- 1379, 1380, 0, 73, 0, 0, 75, 76, 77, 78,
- 0, 0, 0, 0, 0, 188, 189, 190, 399, 0,
- 0, 73, 400, 0, 75, 76, 77, 78, 79, 0,
- 0, 387, 388, 389, 401, 0, 0, 82, 85, 0,
- 0, 83, 0, 0, 0, 0, 0, 0, 0, 84,
- 0, 0, 0, 0, 0, 239, 85, 0, 217, 218,
- 219, 220, 221, 222, 223, 224, 225, 226, 227, 0,
- 228, 229, 230, 86, 191, 0, 513, 87, 88, 0,
- 0, 0, 0, 0, 0, 0, 639, 192, 193, 0,
- 191, 0, 0, 0, 93, 87, 88, 1472, 0, 95,
- 0, 89, 1598, 192, 193, 0, 0, 0, 0, 402,
- 403, 92, 93, 0, 0, 94, 0, 95, 0, 0,
- 0, 0, 640, 0, 0, 0, 194, 195, 0, 196,
- 0, 0, 0, 0, 0, 197, 0, 198, 641, 0,
- 0, 1627, 390, 195, 0, 196, 0, 0, 0, 0,
- 0, 197, 262, 198, 1243, 1244, 1245, 1246, 1247, 1248,
- 1249, 1250, 1251, 1252, 1253, 0, 1254, 1255, 1256, 1257,
- 1258, 1259, 1260, 1261, 1262, 1263, 1264, 1265, 0, 0,
- 385, 0, 0, 0, 1086, 1266, 1267, 1268, 1269, 1270,
- 1271, 1272, 1273, 1274, 1275, 1276, 1277, 1278, 1279, 1280,
- 1281, 1282, 1283, 1284, 0, 0, 1285, 1286, 1287, 1288,
- 1289, 1290, 1291, 1292, 1293, 1294, 1295, 1296, 1297, 1298,
- 1299, 1300, 1301, 1302, 1303, 0, 1304, 0, 1305, 1306,
- 1307, 1308, 1309, 1310, 1311, 1312, 1313, 1314, 0, 1315,
- 1316, 1317, 0, 0, 0, 0, 0, 0, 0, 0,
- 1601, 0, 0, 0, 0, 0, 0, 0, 1318, 0,
- 0, 0, 0, 0, 0, 1319, 1320, 1321, 1322, 1323,
- 1324, 1325, 1326, 1327, 1328, 1329, 1330, 1331, 1332, 1333,
- 1334, 1335, 1336, 1337, 1338, 1339, 1340, 1341, 1342, 1343,
- 1344, 1345, 1346, 1347, 1348, 1349, 1350, 1351, 1352, 1353,
- 1354, 1355, 1356, 1357, 0, 0, 0, 1358, 1359, 1360,
- 1361, 1362, 1363, 1364, 1365, 1366, 1367, 1368, 1369, 1370,
- 1371, 1372, 1373, 1374, 1375, 1376, 1377, 1378, 0, 1379,
- 1380, 7, 8, 9, 10, 0, 11, 12, 13, 171,
- 71, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 207, 208, 209, 210, 211, 212, 213,
- 214, 215, 0, 0, 0, 0, 0, 0, 0, 15,
- 72, 216, 0, 172, 74, 0, 173, 174, 175, 176,
- 79, 80, 0, 0, 0, 21, 81, 0, 0, 177,
- 23, 0, 0, 83, 0, 0, 0, 0, 0, 24,
- 25, 178, 0, 0, 0, 27, 0, 0, 179, 29,
- 30, 31, 32, 33, 34, 35, 36, 37, 38, 39,
- 40, 41, 42, 43, 44, 180, 0, 0, 0, 0,
- 0, 0, 0, 0, 46, 0, 47, 48, 0, 49,
- 0, 0, 0, 0, 50, 0, 0, 181, 182, 53,
- 0, 0, 54, 89, 0, 0, 0, 55, 0, 0,
- 56, 90, 91, 92, 183, 0, 0, 94, 0, 184,
- 7, 8, 9, 10, 0, 11, 12, 13, 398, 0,
- 0, 0, 59, 0, 0, 60, 61, 62, 0, 0,
- 63, 0, 64, 65, 0, 0, 66, 0, 217, 218,
- 219, 220, 221, 222, 223, 224, 225, 226, 227, 0,
- 228, 229, 230, 0, 0, 0, 1022, 0, 15, 399,
- 0, 0, 172, 400, 0, 173, 174, 175, 176, 79,
- 0, 0, 0, 0, 21, 401, 0, 0, 177, 23,
- 0, 0, 83, 0, 0, 0, 0, 0, 24, 25,
- 178, 0, 0, 0, 27, 0, 0, 179, 29, 30,
- 31, 32, 33, 34, 35, 36, 37, 38, 39, 40,
- 41, 42, 43, 44, 180, 0, 0, 0, 0, 0,
- 0, 0, 0, 46, 0, 47, 48, 0, 49, 0,
- 0, 0, 0, 50, 0, 0, 181, 182, 53, 0,
- 0, 54, 89, 0, 0, 0, 55, 0, 0, 56,
- 402, 403, 92, 183, 0, 0, 94, 0, 184, 0,
- 7, 8, 9, 10, 0, 11, 12, 13, 14, 0,
- 0, 59, 159, 0, 60, 61, 62, 0, 0, 63,
- 0, 64, 65, 0, 0, 66, 0, 0, 0, 0,
- 0, 207, 208, 209, 210, 211, 212, 213, 214, 215,
- 0, 0, 0, 0, 0, 0, 0, 0, 15, 216,
- 0, 0, 16, 0, 0, 17, 18, 19, 20, 0,
- 0, 0, 0, 0, 21, 0, 0, 0, 22, 23,
- 0, 0, 0, 0, 0, 0, 0, 0, 24, 25,
- 26, 0, 0, 0, 27, 0, 0, 28, 29, 30,
- 31, 32, 33, 34, 35, 36, 37, 38, 39, 40,
- 41, 42, 43, 44, 45, 0, 0, 0, 0, 0,
- 0, 0, 0, 46, 0, 47, 48, 0, 49, 0,
- 0, 0, 0, 50, 0, 0, 51, 52, 53, 0,
- 0, 54, 0, 0, 0, 0, 55, 0, 0, 56,
- 0, 0, 0, 57, 7, 8, 9, 10, 58, 11,
- 12, 13, 14, 0, 0, 0, 0, 0, 0, 0,
- 0, 59, 0, 0, 60, 61, 62, 0, 0, 63,
- 0, 160, 65, 0, 0, 66, 217, 218, 219, 220,
- 221, 222, 223, 224, 225, 226, 227, 0, 228, 229,
- 230, 0, 15, 0, 1633, 0, 16, 0, 0, 17,
- 18, 19, 20, 0, 0, 0, 0, 0, 21, 188,
- 189, 190, 22, 23, 0, 0, 0, 0, 0, 0,
- 0, 0, 24, 25, 26, 0, 0, 0, 27, 0,
- 0, 28, 29, 30, 31, 32, 33, 34, 35, 36,
- 37, 38, 39, 40, 41, 42, 43, 44, 45, 0,
- 0, 0, 0, 0, 0, 0, 0, 46, 0, 47,
- 48, 0, 49, 0, 0, 0, 0, 50, 191, 0,
- 51, 52, 53, 0, 0, 54, 0, 0, 0, 0,
- 55, 192, 193, 56, 0, 0, 0, 57, 7, 8,
- 9, 10, 58, 11, 12, 13, 14, 0, 0, 0,
- 0, 0, 0, 0, 0, 59, 0, 0, 60, 61,
- 62, 0, 0, 63, 0, 64, 65, 351, 0, 66,
- 194, 195, 0, 196, 0, 0, 0, 0, 0, 197,
- 0, 198, 0, 0, 0, 0, 15, 356, 0, 0,
- 16, 0, 0, 17, 18, 19, 20, 0, 0, 0,
- 0, 0, 21, 0, 0, 754, 22, 23, 0, 0,
- 0, 659, 0, 0, 0, 0, 24, 25, 26, 0,
- 0, 0, 27, 0, 0, 28, 29, 30, 31, 32,
- 33, 34, 35, 36, 37, 38, 39, 40, 41, 42,
- 43, 44, 45, 0, 0, 0, 0, 0, 0, 0,
- 0, 46, 0, 47, 48, 0, 49, 660, 0, 661,
- 0, 50, 0, 0, 51, 52, 53, 0, 0, 54,
- 0, 0, 0, 0, 55, 0, 662, 56, 0, 0,
- 0, 57, 7, 8, 9, 10, 58, 11, 12, 13,
- 14, 0, 0, 0, 0, 0, 0, 0, 0, 59,
- 0, 0, 60, 61, 62, 0, 0, 63, 663, 64,
- 65, 664, 665, 66, 0, 666, 0, 0, 207, 208,
- 209, 210, 211, 212, 213, 214, 215, 0, 0, 0,
- 15, 743, 667, 0, 16, 0, 216, 17, 18, 19,
- 20, 0, 0, 0, 668, 0, 21, 0, 0, 0,
- 22, 23, 0, 0, 0, 0, 0, 0, 669, 0,
- 24, 25, 26, 0, 0, 0, 27, 0, 0, 28,
- 29, 30, 31, 32, 33, 34, 35, 36, 37, 38,
- 39, 40, 41, 42, 43, 44, 45, 0, 0, 0,
- 0, 0, 0, 0, 0, 46, 0, 47, 48, 0,
- 49, 0, 0, 0, 0, 50, 0, 0, 51, 52,
- 53, 0, 0, 54, 0, 0, 0, 0, 55, 0,
- 0, 56, 0, 0, 0, 57, 7, 8, 9, 10,
- 58, 11, 12, 13, 14, 0, 0, 0, 0, 0,
- 0, 0, 0, 59, 0, 0, 60, 61, 62, 0,
- 0, 63, 0, 64, 65, 0, 0, 66, 0, 0,
- 0, 511, 0, 217, 218, 219, 220, 221, 222, 223,
- 224, 225, 226, 227, 15, 228, 229, 230, 16, 0,
- 0, 17, 18, 19, 20, 0, 0, 0, 0, 0,
- 21, 0, 0, 0, 22, 23, 0, 0, 0, 0,
- 0, 0, 0, 0, 24, 25, 26, 0, 0, 0,
- 27, 0, 0, 28, 29, 30, 31, 32, 33, 34,
- 35, 36, 37, 38, 39, 40, 41, 42, 43, 44,
- 45, 0, 0, 0, 0, 0, 0, 0, 0, 46,
- 0, 47, 48, 0, 49, 0, 0, 0, 0, 50,
- 0, 0, 51, 52, 53, 0, 0, 54, 0, 0,
- 0, 0, 55, 0, 0, 56, 0, 0, 0, 57,
- 7, 8, 9, 10, 58, 11, 12, 13, 14, 0,
- 0, 0, 0, 0, 0, 0, 0, 59, 0, 0,
- 60, 61, 62, 0, 0, 63, 0, 64, 65, 876,
- 0, 66, 0, 0, 0, 0, 207, 208, 209, 210,
- 211, 212, 213, 214, 215, 0, 0, 0, 15, 0,
- 0, 0, 16, 0, 216, 17, 18, 19, 20, 0,
- 0, 0, 0, 0, 21, 0, 0, 0, 22, 23,
- 0, 0, 0, 0, 0, 0, 0, 0, 24, 25,
- 26, 0, 0, 0, 27, 0, 0, 28, 29, 30,
- 31, 32, 33, 34, 35, 36, 37, 38, 39, 40,
- 41, 42, 43, 44, 45, 0, 0, 0, 0, 0,
- 0, 0, 0, 46, 0, 47, 48, 0, 49, 0,
- 0, 0, 0, 50, 0, 0, 51, 52, 53, 0,
- 0, 54, 0, 0, 0, 0, 55, 0, 0, 56,
- 0, 0, 0, 57, 7, 8, 9, 10, 58, 11,
- 12, 13, 14, 1083, 0, 0, 0, 0, 0, 0,
- 0, 59, 0, 0, 60, 61, 62, 0, 0, 63,
- 0, 64, 65, 0, 0, 66, 0, 0, 0, 1020,
- 0, 217, 218, 219, 220, 221, 222, 223, 224, 225,
- 226, 227, 15, 228, 229, 230, 16, 0, 0, 17,
- 18, 19, 20, 0, 0, 0, 0, 0, 21, 0,
- 0, 0, 22, 23, 0, 0, 0, 0, 0, 0,
- 0, 0, 24, 25, 26, 0, 0, 0, 27, 0,
- 0, 28, 29, 30, 31, 32, 33, 34, 35, 36,
- 37, 38, 39, 40, 41, 42, 43, 44, 45, 0,
- 0, 0, 0, 0, 0, 0, 0, 46, 0, 47,
- 48, 0, 49, 0, 0, 0, 0, 50, 0, 0,
- 51, 52, 53, 0, 0, 54, 0, 0, 0, 0,
- 55, 0, 0, 56, 0, 0, 0, 57, 7, 8,
- 9, 10, 58, 11, 12, 13, 14, 1471, 0, 0,
- 0, 0, 0, 0, 0, 59, 0, 0, 60, 61,
- 62, 0, 0, 63, 0, 64, 65, 0, 0, 66,
- 207, 208, 209, 210, 211, 212, 213, 214, 215, 0,
- 0, 0, 0, 0, 0, 0, 15, 0, 216, 0,
- 16, 0, 0, 17, 18, 19, 20, 0, 0, 0,
- 0, 0, 21, 0, 0, 0, 22, 23, 0, 0,
- 0, 0, 0, 0, 0, 0, 24, 25, 26, 0,
- 0, 0, 27, 0, 0, 28, 29, 30, 31, 32,
- 33, 34, 35, 36, 37, 38, 39, 40, 41, 42,
- 43, 44, 45, 0, 0, 0, 0, 0, 0, 0,
- 0, 46, 0, 47, 48, 0, 49, 0, 0, 0,
- 0, 50, 0, 0, 51, 52, 53, 0, 0, 54,
- 0, 0, 0, 0, 55, 0, 0, 56, 0, 0,
- 0, 57, 7, 8, 9, 10, 58, 11, 12, 13,
- 14, 0, 0, 0, 0, 0, 0, 0, 0, 59,
- 0, 0, 60, 61, 62, 0, 0, 63, 0, 64,
- 65, 1599, 1088, 66, 0, 217, 218, 219, 220, 221,
- 222, 223, 224, 225, 226, 227, 0, 228, 229, 230,
- 15, 0, 0, 0, 16, 0, 0, 17, 18, 19,
- 20, 0, 0, 0, 0, 0, 21, 0, 0, 0,
- 22, 23, 0, 0, 0, 0, 0, 0, 0, 0,
- 24, 25, 26, 0, 0, 0, 27, 0, 0, 28,
- 29, 30, 31, 32, 33, 34, 35, 36, 37, 38,
- 39, 40, 41, 42, 43, 44, 45, 0, 0, 0,
- 0, 0, 0, 0, 0, 46, 0, 47, 48, 0,
- 49, 0, 0, 0, 0, 50, 0, 0, 51, 52,
- 53, 0, 0, 54, 0, 0, 0, 0, 55, 0,
- 0, 56, 0, 0, 0, 57, 7, 8, 9, 10,
- 58, 11, 12, 13, 14, 0, 1518, 1519, 1520, 1521,
- 1522, 1523, 1524, 59, 0, 0, 60, 61, 62, 0,
- 0, 63, 1525, 64, 65, 0, 0, 66, 0, 0,
- 0, 0, 207, 208, 209, 210, 211, 212, 213, 214,
- 215, 0, 0, 0, 15, 0, 0, 0, 16, 0,
- 216, 17, 18, 19, 20, 0, 0, 0, 0, 0,
- 21, 0, 0, 0, 22, 23, 0, 0, 0, 0,
- 0, 0, 0, 0, 24, 25, 26, 0, 0, 0,
- 27, 0, 0, 28, 29, 30, 31, 32, 33, 34,
- 35, 36, 37, 38, 39, 40, 41, 42, 43, 44,
- 45, 0, 0, 0, 0, 0, 0, 0, 0, 46,
- 0, 47, 48, 0, 49, 0, 0, 0, 0, 50,
- 0, 0, 51, 52, 53, 0, 0, 54, 0, 0,
- 0, 0, 55, 0, 0, 56, 0, 0, 0, 57,
- 7, 8, 9, 10, 58, 11, 12, 13, 0, 0,
- 0, 0, 1504, 0, 0, 1530, 1531, 1532, 1533, 1534,
- 0, 1535, 1536, 1537, 0, 63, 0, 64, 65, 0,
- 0, 66, 0, 894, 0, 0, 0, 217, 218, 219,
- 220, 221, 222, 223, 224, 225, 226, 227, 1439, 228,
- 229, 230, 895, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 1440, 188, 189, 190, 0, 1441,
- 0, 0, 0, 0, 0, 0, 0, 0, 24, 25,
- 0, 0, 0, 0, 27, 0, 0, 0, 29, 30,
- 31, 32, 33, 34, 35, 36, 37, 38, 39, 40,
- 41, 42, 43, 44, 7, 8, 9, 10, 0, 11,
- 12, 13, 0, 0, 0, 0, 48, 0, 49, 0,
- 0, 0, 0, 1442, 191, 0, 0, 0, 1443, 0,
- 632, 1444, 0, 0, 0, 0, 55, 192, 193, 0,
- 207, 208, 209, 210, 211, 212, 213, 214, 215, 0,
- 0, 0, 1439, 0, 0, 0, 0, 0, 216, 0,
- 0, 1445, 0, 0, 1446, 1447, 1448, 0, 1440, 1449,
- 633, 1505, 65, 1441, 0, 1451, 194, 195, 0, 196,
- 0, 0, 24, 25, 0, 197, 0, 198, 27, 0,
- 0, 0, 29, 30, 31, 32, 33, 34, 35, 36,
- 37, 38, 39, 40, 41, 42, 43, 44, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 48, 0, 49, 0, 0, 0, 0, 1442, 0, 0,
- 0, 0, 1443, 0, 0, 1444, 555, 556, 557, 10,
- 55, 11, 558, 559, 0, 0, 0, 0, 852, 0,
- 0, 0, 0, 555, 556, 557, 10, 0, 11, 558,
- 559, 0, 0, 0, 0, 704, 0, 0, 0, 0,
- 0, 0, 0, 1449, 0, 1450, 65, 0, 0, 1451,
- 0, 110, 0, 111, 561, 217, 218, 219, 220, 221,
- 222, 223, 224, 225, 226, 227, 0, 228, 229, 230,
- 562, 561, 0, 0, 0, 563, 0, 0, 0, 0,
- 0, 0, 0, 0, 564, 565, 0, 562, 0, 0,
- 0, 0, 563, 209, 210, 211, 212, 213, 214, 215,
- 0, 564, 565, 0, 0, 0, 0, 0, 0, 216,
- 0, 0, 1518, 1519, 1520, 1521, 1522, 1523, 1524, 566,
- 0, 0, 567, 0, 568, 0, 0, 0, 1525, 569,
- 0, 0, 0, 0, 570, 0, 566, 571, 0, 567,
- 0, 568, 572, 0, 0, 573, 569, 0, 0, 0,
- 0, 570, 0, 0, 571, 0, 0, 0, 0, 572,
- 0, 0, 573, 0, 0, 0, 0, 574, 0, 0,
- 575, 576, 0, 0, 0, 577, 0, 578, 0, 0,
- 0, 579, 0, 0, 574, 0, 0, 575, 576, 1092,
- 0, 0, 577, 0, 705, 0, 0, 0, 579, 1093,
- 1094, 1095, 1096, 1097, 1098, 1099, 1100, 1101, 0, 0,
- 0, 0, 0, 0, 188, 189, 190, 1102, 0, 1103,
- 1104, 1105, 1106, 1107, 1108, 1109, 1110, 1111, 1112, 1113,
- 1114, 0, 0, 0, 0, 0, 0, 218, 219, 220,
- 221, 222, 223, 224, 225, 226, 227, 0, 228, 229,
- 230, 0, 0, 1115, 0, 0, 1527, 1528, 1529, 637,
- 638, 1530, 1531, 1532, 1533, 1534, 0, 1535, 1536, 1537,
- 0, 0, 0, 191, 0, 0, 0, 0, 0, 0,
- 211, 212, 213, 214, 215, 0, 192, 193, 0, 0,
- 0, 0, 0, 0, 216, 0, 0, 0, 0, 1116,
- 0, 399, 0, 0, 73, 400, 0, 75, 76, 77,
- 78, 79, 0, 0, 0, 0, 0, 401, 0, 0,
- 82, 0, 0, 0, 83, 194, 195, 0, 196, 0,
- 0, 0, 84, 0, 197, 0, 198, 0, 0, 85,
- 1117, 0, 0, 1118, 0, 1119, 1120, 1121, 1122, 1123,
- 1124, 1125, 1126, 1127, 1128, 1129, 86, 1130, 1131, 766,
- 767, 1132, 0, 0, 0, 0, 0, 0, 0, 639,
- 0, 0, 0, 0, 0, 0, 0, 0, 87, 88,
- 0, 0, 0, 0, 89, 0, 0, 0, 0, 0,
- 0, 0, 402, 403, 92, 93, 0, 0, 94, 0,
- 95, 399, 0, 0, 73, 400, 0, 75, 76, 77,
- 78, 79, 0, 0, 0, 0, 0, 401, 0, 0,
- 82, 641, 0, 0, 83, 221, 222, 223, 224, 225,
- 226, 227, 84, 228, 229, 230, 0, 0, 0, 85,
- 207, 208, 209, 210, 211, 212, 213, 214, 215, 0,
- 0, 0, 0, 0, 0, 0, 86, 0, 216, 207,
- 208, 209, 210, 211, 212, 213, 214, 215, 0, 639,
- 0, 0, 0, 0, 0, 0, 0, 216, 87, 88,
- 0, 0, 0, 73, 89, 0, 75, 76, 77, 78,
- 0, 0, 402, 403, 92, 93, 0, 0, 94, 238,
- 95, 207, 208, 209, 210, 211, 212, 213, 214, 215,
- 0, 0, 0, 0, 0, 0, 0, 0, 85, 216,
- 0, 641, 207, 208, 209, 210, 211, 212, 213, 214,
- 215, 0, 0, 0, 0, 239, 0, 0, 0, 0,
- 216, 207, 208, 209, 210, 211, 212, 213, 214, 215,
- 0, 0, 0, 0, 0, 0, 0, 87, 88, 216,
- 207, 208, 209, 210, 211, 212, 213, 214, 215, 0,
- 0, 0, 0, 0, 93, 0, 0, 0, 216, 95,
- 0, 0, 0, 0, 0, 217, 218, 219, 220, 221,
- 222, 223, 224, 225, 226, 227, 0, 228, 229, 230,
- 308, 0, 144, 0, 217, 218, 219, 220, 221, 222,
- 223, 224, 225, 226, 227, 0, 228, 229, 230, 499,
- 207, 208, 209, 210, 211, 212, 213, 214, 215, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 216, 0,
- 0, 0, 0, 0, 0, 0, 217, 218, 219, 220,
- 221, 222, 223, 224, 225, 226, 227, 0, 228, 229,
- 230, 515, 0, 0, 0, 0, 0, 217, 218, 219,
- 220, 221, 222, 223, 224, 225, 226, 227, 0, 228,
- 229, 230, 594, 0, 0, 0, 217, 218, 219, 220,
- 221, 222, 223, 224, 225, 226, 227, 0, 228, 229,
- 230, 651, 0, 0, 0, 217, 218, 219, 220, 221,
- 222, 223, 224, 225, 226, 227, 0, 228, 229, 230,
- 752, 207, 208, 209, 210, 211, 212, 213, 214, 215,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 216,
- 207, 208, 209, 210, 211, 212, 213, 214, 215, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 216, 0,
- 0, 0, 0, 0, 0, 217, 218, 219, 220, 221,
- 222, 223, 224, 225, 226, 227, 0, 228, 229, 230,
- 880, 207, 208, 209, 210, 211, 212, 213, 214, 215,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 216,
- 719, 720, 721, 722, 723, 724, 725, 726, 727, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 728, 209,
- 210, 211, 212, 213, 214, 215, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 216, 1518, 1519, 1520, 1521,
- 1522, 1523, 1524, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 1525, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 217, 218, 219, 220,
- 221, 222, 223, 224, 225, 226, 227, 0, 228, 229,
- 230, 962, 0, 0, 0, 217, 218, 219, 220, 221,
- 222, 223, 224, 225, 226, 227, 0, 228, 229, 230,
- 1018, 1518, 1519, 1520, 1521, 1522, 1523, 1524, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 1525, 0, 0,
- 0, 0, 1412, 0, 0, 0, 217, 218, 219, 220,
- 221, 222, 223, 224, 225, 226, 227, 0, 228, 229,
- 230, 0, 0, 0, 0, 729, 730, 731, 732, 733,
- 734, 735, 736, 737, 738, 739, 0, 740, 741, 742,
- 601, 0, 0, 659, 219, 220, 221, 222, 223, 224,
- 225, 226, 227, 0, 228, 229, 230, 0, 0, 0,
- 0, 1528, 1529, 0, 0, 1530, 1531, 1532, 1533, 1534,
- 0, 1535, 1536, 1537, 110, 0, 111, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 413, 660,
- 0, 661, 0, 0, 0, 0, 0, 414, 415, 416,
- 417, 0, 0, 0, 0, 0, 0, 0, 662, 0,
- 419, 420, 421, 422, 0, 601, 0, 0, 0, 0,
- 0, 0, 0, 535, 0, 0, 0, 1529, 0, 0,
- 1530, 1531, 1532, 1533, 1534, 0, 1535, 1536, 1537, 0,
- 663, 0, 0, 664, 665, 0, 0, 666, 432, 0,
- 0, 896, 897, 898, 0, 0, 0, 0, 0, 437,
- 0, 0, 0, 413, 667, 0, 438, 0, 0, 0,
- 440, 441, 414, 415, 416, 417, 668, 0, 0, 0,
- 0, 0, 444, 0, 445, 419, 534, 421, 422, 0,
- 669, 0, 0, 0, 0, 0, 73, 0, 535, 75,
- 76, 77, 78, 899, 900, 896, 897, 898, 0, 0,
- 0, 0, 82, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 432, 84, 0, 0, 0, 0, 0,
- 0, 85, 0, 0, 437, 0, 0, 0, 0, 0,
- 0, 438, 0, 0, 0, 0, 441, 0, 86, 0,
- 73, 0, 0, 75, 76, 77, 78, 444, 0, 445,
- 0, 0, 0, 70, 71, 0, 82, 0, 0, 0,
- 87, 88, 0, 0, 0, 0, 0, 0, 84, 0,
- 0, 0, 0, 0, 901, 85, 0, 93, 0, 0,
- 94, 902, 95, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 86, 0, 72, 0, 0, 73, 74, 0,
- 75, 76, 77, 78, 79, 80, 0, 0, 0, 0,
- 81, 0, 0, 82, 87, 88, 0, 83, 70, 71,
- 0, 0, 0, 0, 0, 84, 0, 0, 0, 0,
- 0, 93, 85, 0, 94, 0, 95, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 86,
- 0, 70, 0, 0, 0, 0, 0, 0, 0, 72,
- 0, 0, 73, 74, 0, 75, 76, 77, 78, 79,
- 0, 87, 88, 0, 0, 81, 0, 89, 82, 0,
- 0, 0, 83, 0, 0, 90, 91, 92, 93, 0,
- 84, 94, 72, 95, 0, 73, 74, 85, 75, 76,
- 77, 78, 79, 777, 0, 0, 0, 0, 81, 0,
- 0, 82, 0, 0, 86, 83, 145, 0, 0, 0,
- 0, 0, 0, 84, 0, 0, 0, 0, 0, 0,
- 85, 0, 0, 0, 0, 0, 87, 88, 0, 0,
- 0, 0, 89, 0, 0, 0, 0, 86, 0, 145,
- 90, 91, 92, 93, 0, 0, 94, 146, 95, 0,
- 73, 147, 0, 75, 76, 77, 78, 79, 965, 87,
- 88, 0, 0, 148, 0, 89, 82, 0, 0, 0,
- 83, 0, 0, 90, 91, 92, 93, 0, 84, 94,
- 146, 95, 0, 73, 147, 85, 75, 76, 77, 78,
- 79, 0, 0, 0, 0, 0, 148, 0, 0, 82,
- 0, 0, 86, 83, 70, 0, 0, 0, 0, 0,
- 0, 84, 0, 0, 0, 0, 0, 0, 85, 0,
- 0, 188, 189, 190, 87, 88, 0, 0, 0, 0,
- 89, 0, 0, 0, 0, 86, 0, 0, 149, 150,
- 92, 93, 0, 0, 94, 72, 95, 0, 73, 74,
- 0, 75, 76, 77, 78, 79, 0, 87, 88, 0,
- 0, 81, 0, 89, 82, 0, 0, 0, 83, 0,
- 0, 149, 150, 92, 93, 0, 84, 94, 0, 95,
- 191, 0, 0, 85, 0, 0, 0, 0, 188, 189,
- 190, 0, 0, 192, 193, 0, 0, 0, 0, 0,
- 86, 0, 0, 188, 189, 190, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 188, 189,
- 190, 0, 87, 88, 0, 0, 0, 0, 89, 0,
- 0, 0, 194, 998, 999, 1000, 90, 91, 92, 93,
- 0, 197, 94, 198, 95, 0, 0, 191, 0, 0,
- 0, 0, 0, 0, 1001, 0, 0, 0, 0, 1002,
- 192, 193, 191, 0, 0, 0, 0, 0, 73, 0,
- 0, 75, 76, 77, 78, 192, 193, 191, 0, 0,
- 188, 189, 190, 0, 0, 1039, 0, 0, 0, 0,
- 192, 193, 73, 0, 0, 75, 76, 77, 78, 194,
- 195, 0, 196, 85, 0, 0, 0, 0, 197, 0,
- 198, 0, 0, 0, 194, 195, 0, 196, 0, 0,
- 239, 1001, 0, 197, 0, 198, 1170, 85, 0, 194,
- 195, 0, 196, 0, 0, 0, 1001, 0, 197, 191,
- 198, 1172, 87, 88, 239, 0, 0, 0, 0, 0,
- 0, 1001, 192, 193, 0, 0, 1174, 0, 0, 93,
- 0, 0, 0, 0, 95, 0, 87, 88, 73, 0,
- 0, 75, 76, 77, 78, 0, 0, 0, 0, 0,
- 0, 0, 0, 93, 0, 0, 0, 157, 95, 0,
- 0, 194, 195, 0, 196, 0, 0, 0, 0, 0,
- 197, 0, 198, 85, 0, 413, 0, 0, 0, 0,
- 0, 158, 0, 0, 414, 415, 416, 417, 0, 0,
- 239, 0, 0, 0, 0, 0, 0, 419, 534, 421,
- 422, 0, 0, 0, 0, 424, 0, 0, 0, 0,
- 535, 0, 87, 88, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 93,
- 0, 0, 0, 0, 95, 432, 0, 0, 0, 412,
- 413, 0, 0, 0, 0, 0, 437, 0, 0, 414,
- 415, 416, 417, 438, 0, 0, 0, 164, 441, 0,
- 418, 0, 419, 420, 421, 422, 423, 0, 443, 444,
- 424, 445, 0, 0, 0, 425, 0, 0, 0, 0,
- 413, 0, 0, 0, 0, 0, -161, 0, 0, 414,
- 415, 416, 417, 0, 426, 427, 428, 429, 430, 431,
- 432, 433, 419, 534, 421, 422, 0, 0, 434, 435,
- 436, 437, 0, 0, 0, 535, 0, 0, 438, 439,
- 413, 0, 440, 441, 0, 0, 0, 442, 0, 414,
- 415, 416, 417, 443, 444, 0, 445, 413, 0, 0,
- 432, 608, 419, 420, 421, 422, 414, 415, 416, 417,
- 424, 437, 0, 0, 0, 535, 0, 0, 438, 419,
- 534, 421, 422, 441, 0, 0, 0, 0, 0, 0,
- 0, 0, 535, 0, 444, 0, 445, 0, 0, 0,
- 432, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 437, 0, 0, 0, 0, 0, 432, 438, 0,
- 0, 0, 440, 441, 0, 0, 0, 0, 437, 0,
- 0, 0, 0, 443, 444, 438, 445, 0, 0, 0,
- 441, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 444, 0, 445
-};
-
-static const yytype_int16 yycheck[] =
-{
- 1, 97, 397, 80, 64, 115, 420, 117, 118, 119,
- 120, 121, 440, 123, 440, 125, 397, 127, 46, 46,
- 374, 506, 1083, 80, 46, 550, 912, 566, 549, 15,
- 266, 266, 10, 13, 144, 13, 934, 768, 396, 86,
- 87, 88, 685, 266, 266, 15, 93, 157, 158, 6,
- 48, 8, 50, 157, 164, 165, 831, 15, 681, 413,
- 414, 415, 416, 417, 65, 419, 420, 421, 62, 967,
- 15, 425, 175, 176, 15, 179, 17, 921, 432, 160,
- 924, 925, 926, 437, 438, 82, 440, 441, 442, 537,
- 444, 445, 617, 0, 175, 96, 97, 10, 11, 12,
- 160, 507, 34, 48, 174, 50, 48, 48, 50, 50,
- 48, 34, 50, 114, 115, 174, 117, 118, 119, 120,
- 121, 157, 123, 82, 125, 6, 127, 8, 48, 34,
- 50, 174, 15, 180, 181, 182, 183, 233, 234, 82,
- 176, 135, 157, 144, 260, 261, 48, 48, 50, 50,
- 48, 174, 50, 249, 250, 251, 157, 158, 539, 156,
- 158, 176, 159, 164, 165, 48, 34, 50, 160, 229,
- 813, 814, 174, 919, 817, 570, 998, 999, 1000, 954,
- 534, 535, 48, 175, 50, 157, 34, 157, 82, 169,
- 176, 169, 239, 157, 552, 305, 160, 156, 174, 157,
- 159, 947, 203, 949, 176, 48, 952, 50, 121, 165,
- 249, 250, 251, 156, 449, 5, 159, 1061, 156, 176,
- 64, 1065, 1066, 164, 955, 160, 449, 449, 169, 754,
- 174, 175, 233, 234, 174, 177, 159, 156, 266, 266,
- 175, 173, 174, 175, 266, 156, 159, 601, 249, 250,
- 251, 174, 175, 254, 779, 174, 165, 177, 157, 798,
- 175, 176, 156, 174, 907, 159, 174, 268, 173, 174,
- 175, 48, 116, 50, 174, 177, 177, 176, 122, 177,
- 124, 157, 126, 174, 128, 129, 130, 131, 132, 133,
- 134, 135, 136, 137, 138, 139, 140, 141, 142, 143,
- 176, 169, 170, 171, 305, 173, 174, 175, 175, 176,
- 1056, 177, 156, 103, 104, 34, 160, 174, 162, 163,
- 174, 1052, 361, 718, 325, 173, 174, 175, 174, 368,
- 369, 974, 34, 818, 177, 978, 979, 718, 385, 1237,
- 157, 153, 154, 155, 1090, 830, 157, 795, 1170, 0,
- 1172, 174, 1174, 157, 174, 1177, 1178, 1179, 981, 176,
- 361, 882, 152, 153, 157, 176, 174, 368, 369, 157,
- 993, 1146, 176, 374, 174, 10, 11, 12, 379, 380,
- 156, 165, 158, 176, 160, 1229, 165, 157, 176, 1135,
- 1136, 626, 1035, 1036, 630, 630, 397, 48, 752, 50,
- 244, 1044, 1045, 626, 626, 1048, 176, 630, 630, 157,
- 1471, 157, 413, 414, 415, 416, 417, 174, 419, 420,
- 421, 449, 449, 157, 425, 174, 965, 449, 176, 174,
- 176, 432, 158, 6, 69, 8, 437, 438, 174, 440,
- 441, 442, 176, 444, 445, 1068, 174, 82, 83, 174,
- 169, 170, 171, 174, 173, 174, 175, 174, 248, 536,
- 304, 157, 252, 253, 174, 167, 168, 169, 170, 171,
- 955, 173, 174, 175, 69, 70, 592, 593, 517, 536,
- 176, 1006, 157, 522, 523, 524, 121, 122, 900, 124,
- 902, 174, 531, 532, 533, 130, 157, 132, 174, 894,
- 1025, 176, 549, 175, 176, 506, 507, 1032, 23, 24,
- 916, 175, 176, 1156, 920, 176, 517, 1140, 578, 34,
- 174, 522, 523, 524, 157, 174, 157, 157, 157, 157,
- 531, 532, 533, 534, 535, 157, 537, 157, 566, 566,
- 157, 176, 174, 176, 566, 176, 176, 176, 176, 550,
- 551, 156, 176, 158, 176, 160, 176, 160, 1202, 176,
- 1204, 174, 639, 174, 970, 971, 972, 1052, 1454, 359,
- 360, 1214, 1215, 1216, 10, 11, 12, 22, 23, 24,
- 1478, 371, 372, 373, 174, 175, 646, 647, 174, 34,
- 174, 10, 11, 12, 654, 174, 656, 174, 626, 626,
- 601, 169, 630, 630, 626, 395, 607, 174, 630, 1037,
- 156, 1037, 158, 156, 160, 158, 617, 160, 408, 409,
- 122, 123, 124, 1037, 156, 157, 470, 174, 472, 156,
- 474, 174, 49, 69, 174, 175, 675, 175, 175, 1385,
- 679, 680, 177, 433, 157, 705, 82, 83, 174, 166,
- 69, 34, 167, 168, 169, 170, 171, 157, 173, 174,
- 175, 166, 778, 82, 83, 1071, 174, 175, 176, 670,
- 176, 787, 176, 156, 675, 158, 159, 160, 679, 680,
- 681, 741, 176, 1037, 685, 121, 122, 176, 124, 174,
- 175, 176, 176, 157, 130, 696, 132, 174, 175, 176,
- 777, 176, 121, 122, 176, 124, 176, 176, 176, 176,
- 176, 130, 166, 132, 10, 11, 12, 13, 508, 176,
- 157, 17, 167, 168, 169, 170, 171, 176, 173, 174,
- 175, 521, 176, 843, 578, 525, 526, 765, 176, 175,
- 166, 160, 176, 176, 176, 164, 590, 15, 176, 176,
- 169, 752, 176, 754, 10, 11, 12, 13, 176, 15,
- 176, 17, 801, 176, 765, 176, 176, 63, 176, 176,
- 798, 798, 176, 176, 174, 1223, 798, 778, 779, 1227,
- 176, 1556, 1557, 1558, 167, 168, 169, 170, 171, 176,
- 173, 174, 175, 159, 795, 1438, 912, 176, 176, 159,
- 801, 591, 174, 919, 594, 921, 174, 63, 924, 925,
- 926, 812, 813, 814, 176, 159, 817, 818, 174, 174,
- 174, 174, 174, 174, 120, 121, 159, 1233, 159, 830,
- 831, 947, 159, 949, 174, 882, 952, 174, 174, 169,
- 174, 176, 843, 175, 634, 82, 13, 176, 15, 175,
- 17, 176, 174, 177, 150, 699, 700, 701, 179, 703,
- 174, 705, 165, 707, 708, 121, 165, 165, 164, 174,
- 966, 127, 900, 169, 902, 165, 176, 165, 174, 176,
- 174, 158, 174, 673, 674, 176, 34, 176, 159, 176,
- 1665, 176, 156, 49, 150, 174, 63, 687, 1673, 174,
- 690, 691, 176, 176, 694, 159, 907, 176, 164, 156,
- 22, 23, 24, 169, 157, 916, 157, 157, 174, 920,
- 921, 157, 34, 924, 925, 926, 157, 157, 156, 174,
- 174, 158, 158, 156, 169, 160, 169, 965, 965, 940,
- 1056, 179, 943, 965, 686, 1061, 175, 156, 166, 1065,
- 1066, 157, 174, 954, 955, 1403, 1404, 1405, 174, 13,
- 127, 15, 174, 17, 166, 966, 176, 166, 176, 970,
- 971, 972, 762, 974, 1090, 166, 176, 978, 979, 10,
- 981, 10, 10, 150, 10, 10, 10, 10, 11, 12,
- 13, 166, 993, 158, 17, 157, 176, 164, 169, 169,
- 1395, 1407, 169, 177, 1410, 1006, 158, 174, 158, 63,
- 1038, 169, 175, 15, 1395, 175, 1464, 174, 157, 1135,
- 1136, 811, 176, 174, 1025, 815, 816, 1028, 174, 819,
- 157, 1032, 176, 823, 1035, 1036, 1037, 827, 828, 174,
- 63, 157, 1043, 1044, 1045, 160, 157, 1048, 1049, 839,
- 1456, 1052, 157, 1149, 1460, 167, 168, 169, 170, 171,
- 1061, 173, 174, 175, 1065, 1066, 169, 1068, 158, 176,
- 1071, 915, 174, 127, 158, 176, 175, 177, 158, 177,
- 157, 10, 1083, 825, 826, 176, 179, 829, 157, 176,
- 179, 177, 174, 176, 884, 176, 150, 1545, 121, 174,
- 176, 179, 10, 10, 127, 1553, 158, 10, 176, 10,
- 164, 1559, 1560, 1229, 158, 169, 10, 13, 10, 15,
- 174, 17, 157, 1183, 1184, 174, 1186, 150, 1188, 1239,
- 1240, 179, 177, 923, 176, 156, 1542, 927, 928, 1140,
- 930, 164, 932, 179, 176, 1146, 169, 157, 1149, 158,
- 165, 174, 174, 165, 1602, 1156, 946, 1605, 176, 165,
- 950, 951, 165, 174, 177, 907, 956, 63, 176, 158,
- 177, 961, 176, 10, 158, 176, 176, 176, 10, 969,
- 10, 158, 158, 973, 10, 158, 174, 15, 1636, 176,
- 176, 176, 65, 157, 984, 985, 177, 1603, 177, 157,
- 166, 1202, 176, 1204, 176, 166, 1654, 166, 176, 166,
- 10, 176, 158, 1214, 1215, 1216, 176, 90, 10, 10,
- 158, 174, 1223, 174, 174, 158, 1227, 176, 1229, 174,
- 158, 127, 1233, 176, 176, 10, 158, 110, 1239, 1240,
- 176, 158, 1238, 607, 986, 1398, 1454, 1038, 990, 991,
- 630, 1562, 1042, 1395, 150, 718, 1046, 1047, 10, 11,
- 12, 13, 570, 630, 1007, 17, 1358, 324, 164, 1385,
- 1060, -1, -1, 169, -1, 2, 149, 20, 21, 22,
- 23, 24, 1398, -1, -1, -1, -1, -1, -1, -1,
- -1, 34, -1, 1035, 1036, -1, -1, -1, -1, 1089,
- -1, -1, 1044, 1045, -1, -1, 1048, -1, -1, -1,
- -1, 63, -1, -1, -1, -1, -1, -1, -1, -1,
- 47, -1, -1, -1, -1, -1, 53, 200, 201, -1,
- -1, -1, 59, 60, 61, 62, 63, -1, 1454, 66,
- -1, -1, -1, 1133, -1, -1, 10, 11, 12, -1,
- -1, -1, -1, -1, -1, 228, -1, 1358, -1, 16,
- 17, 18, 19, 20, 21, 22, 23, 24, 1212, 121,
- -1, -1, -1, -1, 247, 127, -1, 34, -1, 16,
- 17, 18, 19, 20, 21, 22, 23, 24, 261, 262,
- 1450, 1181, -1, -1, 1395, -1, -1, 34, 150, -1,
- 1190, -1, 1403, 1404, 1405, 69, 1407, -1, -1, 1410,
- 1200, -1, 164, -1, -1, -1, -1, 169, 82, 83,
- 1162, -1, -1, 1213, 167, 168, 169, 170, 171, -1,
- 173, 174, 175, 306, 307, -1, 163, 1438, -1, 312,
- -1, -1, -1, -1, -1, 1505, -1, -1, -1, -1,
- -1, 324, -1, -1, -1, 1456, -1, 121, 122, 1460,
- 124, -1, -1, 1464, 23, 24, 130, -1, 132, -1,
- 1471, -1, 1214, 1215, 1216, 34, 1536, -1, -1, 143,
- 207, 208, 209, 210, 211, 212, 213, 214, 215, 216,
- 217, 218, 219, 220, 221, 222, 223, 224, 225, 226,
- 227, -1, 1217, 230, 161, 162, 163, 164, 235, -1,
- 167, 168, 169, 170, 171, -1, 173, 174, 175, -1,
- -1, -1, 159, 396, 161, 162, 163, 164, -1, 402,
- 167, 168, 169, 170, 171, -1, 173, 174, 175, 266,
- -1, 1542, -1, -1, 1545, -1, -1, -1, -1, -1,
- -1, -1, 1553, -1, -1, 1556, 1557, 1558, 1559, 1560,
- -1, 1562, -1, -1, -1, -1, -1, -1, -1, -1,
- 443, -1, -1, -1, -1, 302, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, 1647, 1648, 1649,
- -1, 1651, 319, 320, -1, -1, -1, 1387, -1, 326,
- -1, 1602, 1603, -1, 1605, -1, 1450, -1, 167, 168,
- 169, 170, 171, -1, 173, 174, 175, -1, 1408, -1,
- -1, 1411, -1, -1, 18, 19, 20, 21, 22, 23,
- 24, -1, 505, 55, -1, 1636, 58, 59, 60, 61,
- 34, 10, 11, 12, -1, -1, -1, 520, -1, 71,
- -1, -1, 379, 1654, -1, -1, 1500, 1501, 1502, 1503,
- -1, 1505, -1, 1507, 1665, 1455, -1, -1, 90, 1459,
- 543, -1, 1673, 1463, -1, -1, -1, -1, -1, 552,
- -1, -1, -1, -1, -1, 107, 1476, -1, -1, 1479,
- 1480, 1481, -1, -1, -1, 422, 1438, -1, -1, -1,
- 69, -1, -1, -1, -1, -1, -1, 129, 130, -1,
- -1, -1, -1, 82, 83, -1, -1, -1, -1, 592,
- 593, -1, -1, -1, 146, -1, -1, -1, 1443, 151,
- 1445, 1446, 1447, 1448, 1449, 608, 1451, 610, 611, 612,
- 613, 614, 615, -1, -1, 618, -1, -1, -1, -1,
- -1, -1, 121, 122, -1, 124, -1, 1547, -1, 632,
- 633, 130, -1, 132, -1, -1, -1, -1, 641, 496,
- 164, 165, 166, 167, 168, 169, 170, 171, -1, 173,
- 174, 175, -1, -1, 511, -1, -1, -1, 1217, -1,
- -1, 3, 4, 5, 6, 164, 8, 9, 10, -1,
- 169, 1516, 1517, 1518, 1519, 1520, 1521, 1522, 1523, 1524,
- 1525, 1526, 1527, 1528, 1529, 1530, 1531, 1532, 1533, 1534,
- 1610, -1, -1, -1, -1, 1615, 1616, 18, 19, 20,
- 21, 22, 23, 24, -1, -1, -1, -1, -1, 51,
- -1, -1, -1, 34, 1634, -1, -1, 574, 575, 576,
- 577, -1, 579, -1, -1, 67, -1, -1, -1, -1,
- 72, 588, 1577, -1, -1, 1655, -1, 740, -1, 81,
- 82, -1, -1, -1, 1664, 87, -1, -1, -1, 91,
- 92, 93, 94, 95, 96, 97, 98, 99, 100, 101,
- 102, 103, 104, 105, 106, -1, -1, 624, 17, 18,
- 19, 20, 21, 22, 23, 24, -1, 119, -1, 121,
- -1, -1, -1, 1628, 126, 34, 1631, -1, -1, 131,
- -1, -1, 134, -1, 797, -1, -1, 139, 17, 18,
- 19, 20, 21, 22, 23, 24, -1, -1, 665, -1,
- -1, -1, -1, -1, -1, 34, -1, -1, -1, 822,
- -1, -1, 164, -1, 681, 167, 168, 169, -1, -1,
- 172, -1, 174, 175, -1, -1, 178, -1, -1, -1,
- -1, -1, 845, -1, 165, 166, 167, 168, 169, 170,
- 171, 708, 173, 174, 175, -1, -1, -1, -1, -1,
- -1, -1, 719, 720, 721, 722, 723, 724, 725, 726,
- 727, 728, 729, 730, 731, 732, 733, 734, 735, 736,
- 737, 738, 739, -1, 1443, 742, 1445, 1446, 1447, 1448,
- 1449, -1, 1451, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, 905, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, 162, 163, 164, 165, 166, 167, 168,
- 169, 170, 171, -1, 173, 174, 175, 784, -1, -1,
- 10, 11, 12, 936, -1, 3, 4, 5, 6, -1,
- 8, 9, 10, 162, 163, 164, -1, 15, 167, 168,
- 169, 170, 171, -1, 173, 174, 175, 1516, 1517, 1518,
- 1519, 1520, 1521, 1522, 1523, 1524, 1525, 1526, 1527, 1528,
- 1529, 1530, 1531, 1532, 1533, 1534, -1, -1, -1, -1,
- 48, -1, 50, 51, -1, -1, -1, -1, -1, 69,
- -1, -1, -1, 850, -1, -1, -1, -1, 1001, 67,
- -1, -1, 82, 83, 72, -1, -1, -1, -1, -1,
- -1, -1, 11, 81, 82, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, 1039, -1, -1, -1,
- -1, 121, 122, -1, 124, -1, -1, -1, 116, -1,
- 130, 119, 132, 121, -1, -1, 55, -1, 126, 58,
- 59, 60, 61, 131, -1, -1, 134, -1, -1, -1,
- -1, 139, 1631, -1, 142, -1, 156, 3, 4, 5,
- 6, -1, 8, 9, 10, 11, 943, -1, -1, -1,
- -1, 90, -1, -1, -1, -1, 164, -1, -1, 167,
- 168, -1, -1, -1, 172, -1, 174, -1, 107, -1,
- 178, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, 981, 51, -1, -1, -1, 55,
- 129, 130, 58, 59, 60, 61, 993, -1, -1, -1,
- 997, 67, -1, 69, 70, 71, 72, 146, -1, -1,
- -1, -1, 151, -1, -1, 81, 82, 83, 1015, -1,
- -1, 87, -1, 1020, 90, 91, 92, 93, 94, 95,
- 96, 97, 98, 99, 100, 101, 102, 103, 104, 105,
- 106, 107, -1, -1, -1, -1, -1, -1, -1, -1,
- 116, -1, 118, 119, -1, 121, -1, -1, -1, -1,
- 126, -1, -1, 129, 130, 131, -1, -1, 134, -1,
- -1, 1068, -1, 139, -1, -1, 142, -1, -1, -1,
- 146, -1, -1, -1, -1, 151, 1083, -1, -1, -1,
- 156, -1, -1, -1, -1, 1238, -1, -1, 164, -1,
- -1, 167, 168, 169, -1, -1, 172, -1, 174, 175,
- -1, -1, 178, -1, -1, 3, 4, 5, 6, 7,
- 8, 9, 10, 11, 12, 13, -1, 15, 16, 17,
- 18, 19, 20, 21, 22, 23, 24, 25, 26, -1,
- -1, 1138, -1, 1140, -1, 1142, 34, 35, 36, 37,
- 38, 39, 40, 41, 42, 43, 44, 45, 46, 47,
- 48, 49, 50, 51, 52, -1, -1, 55, 56, 57,
- 58, 59, 60, 61, 62, 63, 64, 65, 66, 67,
- 68, 69, 70, 71, 72, 73, -1, 75, -1, 77,
- 78, 79, 80, 81, 82, 83, 84, 85, 86, -1,
- 88, 89, 90, 16, 17, 18, 19, 20, 21, 22,
- 23, 24, -1, -1, -1, -1, -1, -1, -1, 107,
- -1, 34, -1, -1, -1, -1, 114, 115, 116, 117,
- 118, 119, 120, 121, 122, 123, 124, 125, 126, 127,
- 128, 129, 130, 131, 132, 133, 134, 135, 136, 137,
- 138, 139, 140, 141, 142, 143, 144, 145, 146, 147,
- 148, 149, 150, 151, 152, -1, 10, 11, 156, 157,
- 158, 159, 160, 161, 162, 163, 164, 165, 166, 167,
- 168, 169, 170, 171, 172, 173, 174, 175, 176, 177,
- 178, 179, -1, 55, -1, -1, 58, 59, 60, 61,
- -1, -1, -1, -1, -1, 10, 11, 12, 52, -1,
- -1, 55, 56, -1, 58, 59, 60, 61, 62, -1,
- -1, 10, 11, 12, 68, -1, -1, 71, 90, -1,
- -1, 75, -1, -1, -1, -1, -1, -1, -1, 83,
- -1, -1, -1, -1, -1, 107, 90, -1, 161, 162,
- 163, 164, 165, 166, 167, 168, 169, 170, 171, -1,
- 173, 174, 175, 107, 69, -1, 179, 129, 130, -1,
- -1, -1, -1, -1, -1, -1, 120, 82, 83, -1,
- 69, -1, -1, -1, 146, 129, 130, 1384, -1, 151,
- -1, 135, 1535, 82, 83, -1, -1, -1, -1, 143,
- 144, 145, 146, -1, -1, 149, -1, 151, -1, -1,
- -1, -1, 156, -1, -1, -1, 121, 122, -1, 124,
- -1, -1, -1, -1, -1, 130, -1, 132, 172, -1,
- -1, 1574, 121, 122, -1, 124, -1, -1, -1, -1,
- -1, 130, 147, 132, 3, 4, 5, 6, 7, 8,
- 9, 10, 11, 12, 13, -1, 15, 16, 17, 18,
- 19, 20, 21, 22, 23, 24, 25, 26, -1, -1,
- 159, -1, -1, -1, 1471, 34, 35, 36, 37, 38,
- 39, 40, 41, 42, 43, 44, 45, 46, 47, 48,
- 49, 50, 51, 52, -1, -1, 55, 56, 57, 58,
- 59, 60, 61, 62, 63, 64, 65, 66, 67, 68,
- 69, 70, 71, 72, 73, -1, 75, -1, 77, 78,
- 79, 80, 81, 82, 83, 84, 85, 86, -1, 88,
- 89, 90, -1, -1, -1, -1, -1, -1, -1, -1,
- 1537, -1, -1, -1, -1, -1, -1, -1, 107, -1,
- -1, -1, -1, -1, -1, 114, 115, 116, 117, 118,
- 119, 120, 121, 122, 123, 124, 125, 126, 127, 128,
- 129, 130, 131, 132, 133, 134, 135, 136, 137, 138,
- 139, 140, 141, 142, 143, 144, 145, 146, 147, 148,
- 149, 150, 151, 152, -1, -1, -1, 156, 157, 158,
- 159, 160, 161, 162, 163, 164, 165, 166, 167, 168,
- 169, 170, 171, 172, 173, 174, 175, 176, -1, 178,
- 179, 3, 4, 5, 6, -1, 8, 9, 10, 11,
- 12, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, 16, 17, 18, 19, 20, 21, 22,
- 23, 24, -1, -1, -1, -1, -1, -1, -1, 51,
- 52, 34, -1, 55, 56, -1, 58, 59, 60, 61,
- 62, 63, -1, -1, -1, 67, 68, -1, -1, 71,
- 72, -1, -1, 75, -1, -1, -1, -1, -1, 81,
- 82, 83, -1, -1, -1, 87, -1, -1, 90, 91,
- 92, 93, 94, 95, 96, 97, 98, 99, 100, 101,
- 102, 103, 104, 105, 106, 107, -1, -1, -1, -1,
- -1, -1, -1, -1, 116, -1, 118, 119, -1, 121,
- -1, -1, -1, -1, 126, -1, -1, 129, 130, 131,
- -1, -1, 134, 135, -1, -1, -1, 139, -1, -1,
- 142, 143, 144, 145, 146, -1, -1, 149, -1, 151,
- 3, 4, 5, 6, -1, 8, 9, 10, 11, -1,
- -1, -1, 164, -1, -1, 167, 168, 169, -1, -1,
- 172, -1, 174, 175, -1, -1, 178, -1, 161, 162,
- 163, 164, 165, 166, 167, 168, 169, 170, 171, -1,
- 173, 174, 175, -1, -1, -1, 179, -1, 51, 52,
- -1, -1, 55, 56, -1, 58, 59, 60, 61, 62,
- -1, -1, -1, -1, 67, 68, -1, -1, 71, 72,
- -1, -1, 75, -1, -1, -1, -1, -1, 81, 82,
- 83, -1, -1, -1, 87, -1, -1, 90, 91, 92,
- 93, 94, 95, 96, 97, 98, 99, 100, 101, 102,
- 103, 104, 105, 106, 107, -1, -1, -1, -1, -1,
- -1, -1, -1, 116, -1, 118, 119, -1, 121, -1,
- -1, -1, -1, 126, -1, -1, 129, 130, 131, -1,
- -1, 134, 135, -1, -1, -1, 139, -1, -1, 142,
- 143, 144, 145, 146, -1, -1, 149, -1, 151, -1,
- 3, 4, 5, 6, -1, 8, 9, 10, 11, -1,
- -1, 164, 15, -1, 167, 168, 169, -1, -1, 172,
- -1, 174, 175, -1, -1, 178, -1, -1, -1, -1,
- -1, 16, 17, 18, 19, 20, 21, 22, 23, 24,
- -1, -1, -1, -1, -1, -1, -1, -1, 51, 34,
- -1, -1, 55, -1, -1, 58, 59, 60, 61, -1,
- -1, -1, -1, -1, 67, -1, -1, -1, 71, 72,
- -1, -1, -1, -1, -1, -1, -1, -1, 81, 82,
- 83, -1, -1, -1, 87, -1, -1, 90, 91, 92,
- 93, 94, 95, 96, 97, 98, 99, 100, 101, 102,
- 103, 104, 105, 106, 107, -1, -1, -1, -1, -1,
- -1, -1, -1, 116, -1, 118, 119, -1, 121, -1,
- -1, -1, -1, 126, -1, -1, 129, 130, 131, -1,
- -1, 134, -1, -1, -1, -1, 139, -1, -1, 142,
- -1, -1, -1, 146, 3, 4, 5, 6, 151, 8,
- 9, 10, 11, -1, -1, -1, -1, -1, -1, -1,
- -1, 164, -1, -1, 167, 168, 169, -1, -1, 172,
- -1, 174, 175, -1, -1, 178, 161, 162, 163, 164,
- 165, 166, 167, 168, 169, 170, 171, -1, 173, 174,
- 175, -1, 51, -1, 179, -1, 55, -1, -1, 58,
- 59, 60, 61, -1, -1, -1, -1, -1, 67, 10,
- 11, 12, 71, 72, -1, -1, -1, -1, -1, -1,
- -1, -1, 81, 82, 83, -1, -1, -1, 87, -1,
- -1, 90, 91, 92, 93, 94, 95, 96, 97, 98,
- 99, 100, 101, 102, 103, 104, 105, 106, 107, -1,
- -1, -1, -1, -1, -1, -1, -1, 116, -1, 118,
- 119, -1, 121, -1, -1, -1, -1, 126, 69, -1,
- 129, 130, 131, -1, -1, 134, -1, -1, -1, -1,
- 139, 82, 83, 142, -1, -1, -1, 146, 3, 4,
- 5, 6, 151, 8, 9, 10, 11, -1, -1, -1,
- -1, -1, -1, -1, -1, 164, -1, -1, 167, 168,
- 169, -1, -1, 172, -1, 174, 175, 176, -1, 178,
- 121, 122, -1, 124, -1, -1, -1, -1, -1, 130,
- -1, 132, -1, -1, -1, -1, 51, 52, -1, -1,
- 55, -1, -1, 58, 59, 60, 61, -1, -1, -1,
- -1, -1, 67, -1, -1, 156, 71, 72, -1, -1,
- -1, 17, -1, -1, -1, -1, 81, 82, 83, -1,
- -1, -1, 87, -1, -1, 90, 91, 92, 93, 94,
- 95, 96, 97, 98, 99, 100, 101, 102, 103, 104,
- 105, 106, 107, -1, -1, -1, -1, -1, -1, -1,
- -1, 116, -1, 118, 119, -1, 121, 63, -1, 65,
- -1, 126, -1, -1, 129, 130, 131, -1, -1, 134,
- -1, -1, -1, -1, 139, -1, 82, 142, -1, -1,
- -1, 146, 3, 4, 5, 6, 151, 8, 9, 10,
- 11, -1, -1, -1, -1, -1, -1, -1, -1, 164,
- -1, -1, 167, 168, 169, -1, -1, 172, 114, 174,
- 175, 117, 118, 178, -1, 121, -1, -1, 16, 17,
- 18, 19, 20, 21, 22, 23, 24, -1, -1, -1,
- 51, 52, 138, -1, 55, -1, 34, 58, 59, 60,
- 61, -1, -1, -1, 150, -1, 67, -1, -1, -1,
- 71, 72, -1, -1, -1, -1, -1, -1, 164, -1,
- 81, 82, 83, -1, -1, -1, 87, -1, -1, 90,
- 91, 92, 93, 94, 95, 96, 97, 98, 99, 100,
- 101, 102, 103, 104, 105, 106, 107, -1, -1, -1,
- -1, -1, -1, -1, -1, 116, -1, 118, 119, -1,
- 121, -1, -1, -1, -1, 126, -1, -1, 129, 130,
- 131, -1, -1, 134, -1, -1, -1, -1, 139, -1,
- -1, 142, -1, -1, -1, 146, 3, 4, 5, 6,
- 151, 8, 9, 10, 11, -1, -1, -1, -1, -1,
- -1, -1, -1, 164, -1, -1, 167, 168, 169, -1,
- -1, 172, -1, 174, 175, -1, -1, 178, -1, -1,
- -1, 159, -1, 161, 162, 163, 164, 165, 166, 167,
- 168, 169, 170, 171, 51, 173, 174, 175, 55, -1,
- -1, 58, 59, 60, 61, -1, -1, -1, -1, -1,
- 67, -1, -1, -1, 71, 72, -1, -1, -1, -1,
- -1, -1, -1, -1, 81, 82, 83, -1, -1, -1,
- 87, -1, -1, 90, 91, 92, 93, 94, 95, 96,
- 97, 98, 99, 100, 101, 102, 103, 104, 105, 106,
- 107, -1, -1, -1, -1, -1, -1, -1, -1, 116,
- -1, 118, 119, -1, 121, -1, -1, -1, -1, 126,
- -1, -1, 129, 130, 131, -1, -1, 134, -1, -1,
- -1, -1, 139, -1, -1, 142, -1, -1, -1, 146,
- 3, 4, 5, 6, 151, 8, 9, 10, 11, -1,
- -1, -1, -1, -1, -1, -1, -1, 164, -1, -1,
- 167, 168, 169, -1, -1, 172, -1, 174, 175, 176,
- -1, 178, -1, -1, -1, -1, 16, 17, 18, 19,
- 20, 21, 22, 23, 24, -1, -1, -1, 51, -1,
- -1, -1, 55, -1, 34, 58, 59, 60, 61, -1,
- -1, -1, -1, -1, 67, -1, -1, -1, 71, 72,
- -1, -1, -1, -1, -1, -1, -1, -1, 81, 82,
- 83, -1, -1, -1, 87, -1, -1, 90, 91, 92,
- 93, 94, 95, 96, 97, 98, 99, 100, 101, 102,
- 103, 104, 105, 106, 107, -1, -1, -1, -1, -1,
- -1, -1, -1, 116, -1, 118, 119, -1, 121, -1,
- -1, -1, -1, 126, -1, -1, 129, 130, 131, -1,
- -1, 134, -1, -1, -1, -1, 139, -1, -1, 142,
- -1, -1, -1, 146, 3, 4, 5, 6, 151, 8,
- 9, 10, 11, 156, -1, -1, -1, -1, -1, -1,
- -1, 164, -1, -1, 167, 168, 169, -1, -1, 172,
- -1, 174, 175, -1, -1, 178, -1, -1, -1, 159,
- -1, 161, 162, 163, 164, 165, 166, 167, 168, 169,
- 170, 171, 51, 173, 174, 175, 55, -1, -1, 58,
- 59, 60, 61, -1, -1, -1, -1, -1, 67, -1,
- -1, -1, 71, 72, -1, -1, -1, -1, -1, -1,
- -1, -1, 81, 82, 83, -1, -1, -1, 87, -1,
- -1, 90, 91, 92, 93, 94, 95, 96, 97, 98,
- 99, 100, 101, 102, 103, 104, 105, 106, 107, -1,
- -1, -1, -1, -1, -1, -1, -1, 116, -1, 118,
- 119, -1, 121, -1, -1, -1, -1, 126, -1, -1,
- 129, 130, 131, -1, -1, 134, -1, -1, -1, -1,
- 139, -1, -1, 142, -1, -1, -1, 146, 3, 4,
- 5, 6, 151, 8, 9, 10, 11, 156, -1, -1,
- -1, -1, -1, -1, -1, 164, -1, -1, 167, 168,
- 169, -1, -1, 172, -1, 174, 175, -1, -1, 178,
- 16, 17, 18, 19, 20, 21, 22, 23, 24, -1,
- -1, -1, -1, -1, -1, -1, 51, -1, 34, -1,
- 55, -1, -1, 58, 59, 60, 61, -1, -1, -1,
- -1, -1, 67, -1, -1, -1, 71, 72, -1, -1,
- -1, -1, -1, -1, -1, -1, 81, 82, 83, -1,
- -1, -1, 87, -1, -1, 90, 91, 92, 93, 94,
- 95, 96, 97, 98, 99, 100, 101, 102, 103, 104,
- 105, 106, 107, -1, -1, -1, -1, -1, -1, -1,
- -1, 116, -1, 118, 119, -1, 121, -1, -1, -1,
- -1, 126, -1, -1, 129, 130, 131, -1, -1, 134,
- -1, -1, -1, -1, 139, -1, -1, 142, -1, -1,
- -1, 146, 3, 4, 5, 6, 151, 8, 9, 10,
- 11, -1, -1, -1, -1, -1, -1, -1, -1, 164,
- -1, -1, 167, 168, 169, -1, -1, 172, -1, 174,
- 175, 176, 158, 178, -1, 161, 162, 163, 164, 165,
- 166, 167, 168, 169, 170, 171, -1, 173, 174, 175,
- 51, -1, -1, -1, 55, -1, -1, 58, 59, 60,
- 61, -1, -1, -1, -1, -1, 67, -1, -1, -1,
- 71, 72, -1, -1, -1, -1, -1, -1, -1, -1,
- 81, 82, 83, -1, -1, -1, 87, -1, -1, 90,
- 91, 92, 93, 94, 95, 96, 97, 98, 99, 100,
- 101, 102, 103, 104, 105, 106, 107, -1, -1, -1,
- -1, -1, -1, -1, -1, 116, -1, 118, 119, -1,
- 121, -1, -1, -1, -1, 126, -1, -1, 129, 130,
- 131, -1, -1, 134, -1, -1, -1, -1, 139, -1,
- -1, 142, -1, -1, -1, 146, 3, 4, 5, 6,
- 151, 8, 9, 10, 11, -1, 18, 19, 20, 21,
- 22, 23, 24, 164, -1, -1, 167, 168, 169, -1,
- -1, 172, 34, 174, 175, -1, -1, 178, -1, -1,
- -1, -1, 16, 17, 18, 19, 20, 21, 22, 23,
- 24, -1, -1, -1, 51, -1, -1, -1, 55, -1,
- 34, 58, 59, 60, 61, -1, -1, -1, -1, -1,
- 67, -1, -1, -1, 71, 72, -1, -1, -1, -1,
- -1, -1, -1, -1, 81, 82, 83, -1, -1, -1,
- 87, -1, -1, 90, 91, 92, 93, 94, 95, 96,
- 97, 98, 99, 100, 101, 102, 103, 104, 105, 106,
- 107, -1, -1, -1, -1, -1, -1, -1, -1, 116,
- -1, 118, 119, -1, 121, -1, -1, -1, -1, 126,
- -1, -1, 129, 130, 131, -1, -1, 134, -1, -1,
- -1, -1, 139, -1, -1, 142, -1, -1, -1, 146,
- 3, 4, 5, 6, 151, 8, 9, 10, -1, -1,
- -1, -1, 15, -1, -1, 167, 168, 169, 170, 171,
- -1, 173, 174, 175, -1, 172, -1, 174, 175, -1,
- -1, 178, -1, 157, -1, -1, -1, 161, 162, 163,
- 164, 165, 166, 167, 168, 169, 170, 171, 51, 173,
- 174, 175, 176, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, 67, 10, 11, 12, -1, 72,
- -1, -1, -1, -1, -1, -1, -1, -1, 81, 82,
- -1, -1, -1, -1, 87, -1, -1, -1, 91, 92,
- 93, 94, 95, 96, 97, 98, 99, 100, 101, 102,
- 103, 104, 105, 106, 3, 4, 5, 6, -1, 8,
- 9, 10, -1, -1, -1, -1, 119, -1, 121, -1,
- -1, -1, -1, 126, 69, -1, -1, -1, 131, -1,
- 75, 134, -1, -1, -1, -1, 139, 82, 83, -1,
- 16, 17, 18, 19, 20, 21, 22, 23, 24, -1,
- -1, -1, 51, -1, -1, -1, -1, -1, 34, -1,
- -1, 164, -1, -1, 167, 168, 169, -1, 67, 172,
- 115, 174, 175, 72, -1, 178, 121, 122, -1, 124,
- -1, -1, 81, 82, -1, 130, -1, 132, 87, -1,
- -1, -1, 91, 92, 93, 94, 95, 96, 97, 98,
- 99, 100, 101, 102, 103, 104, 105, 106, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- 119, -1, 121, -1, -1, -1, -1, 126, -1, -1,
- -1, -1, 131, -1, -1, 134, 3, 4, 5, 6,
- 139, 8, 9, 10, -1, -1, -1, -1, 15, -1,
- -1, -1, -1, 3, 4, 5, 6, -1, 8, 9,
- 10, -1, -1, -1, -1, 15, -1, -1, -1, -1,
- -1, -1, -1, 172, -1, 174, 175, -1, -1, 178,
- -1, 48, -1, 50, 51, 161, 162, 163, 164, 165,
- 166, 167, 168, 169, 170, 171, -1, 173, 174, 175,
- 67, 51, -1, -1, -1, 72, -1, -1, -1, -1,
- -1, -1, -1, -1, 81, 82, -1, 67, -1, -1,
- -1, -1, 72, 18, 19, 20, 21, 22, 23, 24,
- -1, 81, 82, -1, -1, -1, -1, -1, -1, 34,
- -1, -1, 18, 19, 20, 21, 22, 23, 24, 116,
- -1, -1, 119, -1, 121, -1, -1, -1, 34, 126,
- -1, -1, -1, -1, 131, -1, 116, 134, -1, 119,
- -1, 121, 139, -1, -1, 142, 126, -1, -1, -1,
- -1, 131, -1, -1, 134, -1, -1, -1, -1, 139,
- -1, -1, 142, -1, -1, -1, -1, 164, -1, -1,
- 167, 168, -1, -1, -1, 172, -1, 174, -1, -1,
- -1, 178, -1, -1, 164, -1, -1, 167, 168, 6,
- -1, -1, 172, -1, 174, -1, -1, -1, 178, 16,
- 17, 18, 19, 20, 21, 22, 23, 24, -1, -1,
- -1, -1, -1, -1, 10, 11, 12, 34, -1, 36,
- 37, 38, 39, 40, 41, 42, 43, 44, 45, 46,
- 47, -1, -1, -1, -1, -1, -1, 162, 163, 164,
- 165, 166, 167, 168, 169, 170, 171, -1, 173, 174,
- 175, -1, -1, 70, -1, -1, 162, 163, 164, 10,
- 11, 167, 168, 169, 170, 171, -1, 173, 174, 175,
- -1, -1, -1, 69, -1, -1, -1, -1, -1, -1,
- 20, 21, 22, 23, 24, -1, 82, 83, -1, -1,
- -1, -1, -1, -1, 34, -1, -1, -1, -1, 116,
- -1, 52, -1, -1, 55, 56, -1, 58, 59, 60,
- 61, 62, -1, -1, -1, -1, -1, 68, -1, -1,
- 71, -1, -1, -1, 75, 121, 122, -1, 124, -1,
- -1, -1, 83, -1, 130, -1, 132, -1, -1, 90,
- 157, -1, -1, 160, -1, 162, 163, 164, 165, 166,
- 167, 168, 169, 170, 171, 172, 107, 174, 175, 10,
- 11, 178, -1, -1, -1, -1, -1, -1, -1, 120,
- -1, -1, -1, -1, -1, -1, -1, -1, 129, 130,
- -1, -1, -1, -1, 135, -1, -1, -1, -1, -1,
- -1, -1, 143, 144, 145, 146, -1, -1, 149, -1,
- 151, 52, -1, -1, 55, 56, -1, 58, 59, 60,
- 61, 62, -1, -1, -1, -1, -1, 68, -1, -1,
- 71, 172, -1, -1, 75, 165, 166, 167, 168, 169,
- 170, 171, 83, 173, 174, 175, -1, -1, -1, 90,
- 16, 17, 18, 19, 20, 21, 22, 23, 24, -1,
- -1, -1, -1, -1, -1, -1, 107, -1, 34, 16,
- 17, 18, 19, 20, 21, 22, 23, 24, -1, 120,
- -1, -1, -1, -1, -1, -1, -1, 34, 129, 130,
- -1, -1, -1, 55, 135, -1, 58, 59, 60, 61,
- -1, -1, 143, 144, 145, 146, -1, -1, 149, 71,
- 151, 16, 17, 18, 19, 20, 21, 22, 23, 24,
- -1, -1, -1, -1, -1, -1, -1, -1, 90, 34,
- -1, 172, 16, 17, 18, 19, 20, 21, 22, 23,
- 24, -1, -1, -1, -1, 107, -1, -1, -1, -1,
- 34, 16, 17, 18, 19, 20, 21, 22, 23, 24,
- -1, -1, -1, -1, -1, -1, -1, 129, 130, 34,
- 16, 17, 18, 19, 20, 21, 22, 23, 24, -1,
- -1, -1, -1, -1, 146, -1, -1, -1, 34, 151,
- -1, -1, -1, -1, -1, 161, 162, 163, 164, 165,
- 166, 167, 168, 169, 170, 171, -1, 173, 174, 175,
- 176, -1, 174, -1, 161, 162, 163, 164, 165, 166,
- 167, 168, 169, 170, 171, -1, 173, 174, 175, 176,
- 16, 17, 18, 19, 20, 21, 22, 23, 24, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, 34, -1,
- -1, -1, -1, -1, -1, -1, 161, 162, 163, 164,
- 165, 166, 167, 168, 169, 170, 171, -1, 173, 174,
- 175, 176, -1, -1, -1, -1, -1, 161, 162, 163,
- 164, 165, 166, 167, 168, 169, 170, 171, -1, 173,
- 174, 175, 176, -1, -1, -1, 161, 162, 163, 164,
- 165, 166, 167, 168, 169, 170, 171, -1, 173, 174,
- 175, 176, -1, -1, -1, 161, 162, 163, 164, 165,
- 166, 167, 168, 169, 170, 171, -1, 173, 174, 175,
- 176, 16, 17, 18, 19, 20, 21, 22, 23, 24,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, 34,
- 16, 17, 18, 19, 20, 21, 22, 23, 24, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, 34, -1,
- -1, -1, -1, -1, -1, 161, 162, 163, 164, 165,
- 166, 167, 168, 169, 170, 171, -1, 173, 174, 175,
- 176, 16, 17, 18, 19, 20, 21, 22, 23, 24,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, 34,
- 16, 17, 18, 19, 20, 21, 22, 23, 24, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, 34, 18,
- 19, 20, 21, 22, 23, 24, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, 34, 18, 19, 20, 21,
- 22, 23, 24, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, 34, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, 161, 162, 163, 164,
- 165, 166, 167, 168, 169, 170, 171, -1, 173, 174,
- 175, 176, -1, -1, -1, 161, 162, 163, 164, 165,
- 166, 167, 168, 169, 170, 171, -1, 173, 174, 175,
- 176, 18, 19, 20, 21, 22, 23, 24, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, 34, -1, -1,
- -1, -1, 157, -1, -1, -1, 161, 162, 163, 164,
- 165, 166, 167, 168, 169, 170, 171, -1, 173, 174,
- 175, -1, -1, -1, -1, 161, 162, 163, 164, 165,
- 166, 167, 168, 169, 170, 171, -1, 173, 174, 175,
- 6, -1, -1, 17, 163, 164, 165, 166, 167, 168,
- 169, 170, 171, -1, 173, 174, 175, -1, -1, -1,
- -1, 163, 164, -1, -1, 167, 168, 169, 170, 171,
- -1, 173, 174, 175, 48, -1, 50, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, 54, 63,
- -1, 65, -1, -1, -1, -1, -1, 63, 64, 65,
- 66, -1, -1, -1, -1, -1, -1, -1, 82, -1,
- 76, 77, 78, 79, -1, 6, -1, -1, -1, -1,
- -1, -1, -1, 89, -1, -1, -1, 164, -1, -1,
- 167, 168, 169, 170, 171, -1, 173, 174, 175, -1,
- 114, -1, -1, 117, 118, -1, -1, 121, 114, -1,
- -1, 10, 11, 12, -1, -1, -1, -1, -1, 125,
- -1, -1, -1, 54, 138, -1, 132, -1, -1, -1,
- 136, 137, 63, 64, 65, 66, 150, -1, -1, -1,
- -1, -1, 148, -1, 150, 76, 77, 78, 79, -1,
- 164, -1, -1, -1, -1, -1, 55, -1, 89, 58,
- 59, 60, 61, 62, 63, 10, 11, 12, -1, -1,
- -1, -1, 71, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, 114, 83, -1, -1, -1, -1, -1,
- -1, 90, -1, -1, 125, -1, -1, -1, -1, -1,
- -1, 132, -1, -1, -1, -1, 137, -1, 107, -1,
- 55, -1, -1, 58, 59, 60, 61, 148, -1, 150,
- -1, -1, -1, 11, 12, -1, 71, -1, -1, -1,
- 129, 130, -1, -1, -1, -1, -1, -1, 83, -1,
- -1, -1, -1, -1, 143, 90, -1, 146, -1, -1,
- 149, 150, 151, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, 107, -1, 52, -1, -1, 55, 56, -1,
- 58, 59, 60, 61, 62, 63, -1, -1, -1, -1,
- 68, -1, -1, 71, 129, 130, -1, 75, 11, 12,
- -1, -1, -1, -1, -1, 83, -1, -1, -1, -1,
- -1, 146, 90, -1, 149, -1, 151, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, 107,
- -1, 11, -1, -1, -1, -1, -1, -1, -1, 52,
- -1, -1, 55, 56, -1, 58, 59, 60, 61, 62,
- -1, 129, 130, -1, -1, 68, -1, 135, 71, -1,
- -1, -1, 75, -1, -1, 143, 144, 145, 146, -1,
- 83, 149, 52, 151, -1, 55, 56, 90, 58, 59,
- 60, 61, 62, 63, -1, -1, -1, -1, 68, -1,
- -1, 71, -1, -1, 107, 75, 11, -1, -1, -1,
- -1, -1, -1, 83, -1, -1, -1, -1, -1, -1,
- 90, -1, -1, -1, -1, -1, 129, 130, -1, -1,
- -1, -1, 135, -1, -1, -1, -1, 107, -1, 11,
- 143, 144, 145, 146, -1, -1, 149, 52, 151, -1,
- 55, 56, -1, 58, 59, 60, 61, 62, 63, 129,
- 130, -1, -1, 68, -1, 135, 71, -1, -1, -1,
- 75, -1, -1, 143, 144, 145, 146, -1, 83, 149,
- 52, 151, -1, 55, 56, 90, 58, 59, 60, 61,
- 62, -1, -1, -1, -1, -1, 68, -1, -1, 71,
- -1, -1, 107, 75, 11, -1, -1, -1, -1, -1,
- -1, 83, -1, -1, -1, -1, -1, -1, 90, -1,
- -1, 10, 11, 12, 129, 130, -1, -1, -1, -1,
- 135, -1, -1, -1, -1, 107, -1, -1, 143, 144,
- 145, 146, -1, -1, 149, 52, 151, -1, 55, 56,
- -1, 58, 59, 60, 61, 62, -1, 129, 130, -1,
- -1, 68, -1, 135, 71, -1, -1, -1, 75, -1,
- -1, 143, 144, 145, 146, -1, 83, 149, -1, 151,
- 69, -1, -1, 90, -1, -1, -1, -1, 10, 11,
- 12, -1, -1, 82, 83, -1, -1, -1, -1, -1,
- 107, -1, -1, 10, 11, 12, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, 10, 11,
- 12, -1, 129, 130, -1, -1, -1, -1, 135, -1,
- -1, -1, 121, 122, 123, 124, 143, 144, 145, 146,
- -1, 130, 149, 132, 151, -1, -1, 69, -1, -1,
- -1, -1, -1, -1, 143, -1, -1, -1, -1, 148,
- 82, 83, 69, -1, -1, -1, -1, -1, 55, -1,
- -1, 58, 59, 60, 61, 82, 83, 69, -1, -1,
- 10, 11, 12, -1, -1, 15, -1, -1, -1, -1,
- 82, 83, 55, -1, -1, 58, 59, 60, 61, 121,
- 122, -1, 124, 90, -1, -1, -1, -1, 130, -1,
- 132, -1, -1, -1, 121, 122, -1, 124, -1, -1,
- 107, 143, -1, 130, -1, 132, 148, 90, -1, 121,
- 122, -1, 124, -1, -1, -1, 143, -1, 130, 69,
- 132, 148, 129, 130, 107, -1, -1, -1, -1, -1,
- -1, 143, 82, 83, -1, -1, 148, -1, -1, 146,
- -1, -1, -1, -1, 151, -1, 129, 130, 55, -1,
- -1, 58, 59, 60, 61, -1, -1, -1, -1, -1,
- -1, -1, -1, 146, -1, -1, -1, 174, 151, -1,
- -1, 121, 122, -1, 124, -1, -1, -1, -1, -1,
- 130, -1, 132, 90, -1, 54, -1, -1, -1, -1,
- -1, 174, -1, -1, 63, 64, 65, 66, -1, -1,
- 107, -1, -1, -1, -1, -1, -1, 76, 77, 78,
- 79, -1, -1, -1, -1, 84, -1, -1, -1, -1,
- 89, -1, 129, 130, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, 146,
- -1, -1, -1, -1, 151, 114, -1, -1, -1, 53,
- 54, -1, -1, -1, -1, -1, 125, -1, -1, 63,
- 64, 65, 66, 132, -1, -1, -1, 174, 137, -1,
- 74, -1, 76, 77, 78, 79, 80, -1, 147, 148,
- 84, 150, -1, -1, -1, 89, -1, -1, -1, -1,
- 54, -1, -1, -1, -1, -1, 165, -1, -1, 63,
- 64, 65, 66, -1, 108, 109, 110, 111, 112, 113,
- 114, 115, 76, 77, 78, 79, -1, -1, 122, 123,
- 124, 125, -1, -1, -1, 89, -1, -1, 132, 133,
- 54, -1, 136, 137, -1, -1, -1, 141, -1, 63,
- 64, 65, 66, 147, 148, -1, 150, 54, -1, -1,
- 114, 115, 76, 77, 78, 79, 63, 64, 65, 66,
- 84, 125, -1, -1, -1, 89, -1, -1, 132, 76,
- 77, 78, 79, 137, -1, -1, -1, -1, -1, -1,
- -1, -1, 89, -1, 148, -1, 150, -1, -1, -1,
- 114, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, 125, -1, -1, -1, -1, -1, 114, 132, -1,
- -1, -1, 136, 137, -1, -1, -1, -1, 125, -1,
- -1, -1, -1, 147, 148, 132, 150, -1, -1, -1,
- 137, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, 148, -1, 150
-};
-
-/* YYSTOS[STATE-NUM] -- The symbol kind of the accessing symbol of
- state STATE-NUM. */
-static const yytype_int16 yystos[] =
-{
- 0, 153, 154, 155, 181, 182, 292, 3, 4, 5,
- 6, 8, 9, 10, 11, 51, 55, 58, 59, 60,
- 61, 67, 71, 72, 81, 82, 83, 87, 90, 91,
- 92, 93, 94, 95, 96, 97, 98, 99, 100, 101,
- 102, 103, 104, 105, 106, 107, 116, 118, 119, 121,
- 126, 129, 130, 131, 134, 139, 142, 146, 151, 164,
- 167, 168, 169, 172, 174, 175, 178, 282, 283, 291,
- 11, 12, 52, 55, 56, 58, 59, 60, 61, 62,
- 63, 68, 71, 75, 83, 90, 107, 129, 130, 135,
- 143, 144, 145, 146, 149, 151, 244, 245, 249, 250,
- 252, 258, 260, 264, 265, 270, 271, 272, 273, 0,
- 48, 50, 192, 292, 156, 174, 174, 174, 174, 174,
- 174, 174, 165, 174, 165, 174, 174, 174, 174, 174,
- 174, 174, 174, 174, 174, 174, 174, 174, 174, 174,
- 174, 174, 174, 174, 174, 11, 52, 56, 68, 143,
- 144, 247, 264, 265, 270, 282, 165, 174, 174, 15,
- 174, 282, 165, 174, 174, 174, 282, 282, 282, 282,
- 282, 11, 55, 58, 59, 60, 61, 71, 83, 90,
- 107, 129, 130, 146, 151, 249, 280, 282, 10, 11,
- 12, 69, 82, 83, 121, 122, 124, 130, 132, 160,
- 164, 169, 286, 287, 289, 292, 282, 16, 17, 18,
- 19, 20, 21, 22, 23, 24, 34, 161, 162, 163,
- 164, 165, 166, 167, 168, 169, 170, 171, 173, 174,
- 175, 6, 8, 244, 245, 174, 62, 135, 71, 107,
- 271, 271, 271, 289, 174, 271, 13, 15, 17, 63,
- 127, 150, 164, 169, 174, 242, 243, 292, 243, 259,
- 192, 192, 147, 193, 194, 289, 174, 158, 183, 279,
- 280, 292, 279, 249, 279, 279, 279, 279, 279, 249,
- 279, 249, 279, 249, 279, 249, 249, 249, 249, 249,
- 249, 249, 249, 249, 249, 249, 249, 249, 249, 249,
- 249, 279, 174, 289, 174, 174, 192, 192, 176, 249,
- 279, 279, 174, 249, 249, 249, 282, 279, 279, 176,
- 157, 176, 289, 289, 157, 179, 160, 232, 292, 282,
- 282, 282, 282, 282, 282, 282, 282, 282, 282, 282,
- 282, 282, 282, 282, 282, 282, 282, 282, 282, 282,
- 289, 176, 280, 282, 243, 243, 52, 282, 249, 169,
- 289, 192, 242, 243, 242, 243, 242, 243, 192, 192,
- 15, 17, 164, 169, 192, 227, 228, 237, 292, 175,
- 156, 10, 11, 12, 121, 159, 290, 10, 11, 12,
- 121, 156, 289, 290, 289, 49, 157, 174, 11, 52,
- 56, 68, 143, 144, 246, 250, 252, 258, 264, 265,
- 270, 282, 53, 54, 63, 64, 65, 66, 74, 76,
- 77, 78, 79, 80, 84, 89, 108, 109, 110, 111,
- 112, 113, 114, 115, 122, 123, 124, 125, 132, 133,
- 136, 137, 141, 147, 148, 150, 186, 188, 189, 191,
- 195, 215, 266, 269, 292, 177, 176, 176, 176, 176,
- 176, 176, 176, 166, 176, 166, 176, 176, 176, 176,
- 157, 176, 157, 176, 157, 176, 176, 176, 176, 176,
- 176, 176, 176, 176, 176, 176, 176, 282, 249, 279,
- 289, 289, 166, 176, 176, 289, 176, 166, 176, 176,
- 176, 176, 282, 282, 15, 164, 287, 174, 212, 292,
- 282, 159, 176, 179, 176, 176, 176, 192, 192, 13,
- 15, 17, 63, 127, 150, 164, 169, 242, 292, 242,
- 242, 192, 192, 192, 77, 89, 191, 176, 15, 157,
- 278, 282, 292, 262, 263, 292, 11, 261, 271, 159,
- 251, 253, 159, 192, 193, 3, 4, 5, 9, 10,
- 15, 51, 67, 72, 81, 82, 116, 119, 121, 126,
- 131, 134, 139, 142, 164, 167, 168, 172, 174, 178,
- 229, 230, 237, 238, 284, 285, 291, 292, 174, 289,
- 174, 176, 192, 192, 176, 191, 191, 191, 191, 191,
- 191, 6, 191, 215, 191, 282, 159, 190, 115, 191,
- 174, 174, 174, 174, 174, 174, 191, 156, 192, 159,
- 159, 159, 191, 191, 174, 189, 191, 195, 216, 191,
- 191, 199, 75, 115, 289, 191, 191, 10, 11, 120,
- 156, 172, 202, 206, 246, 248, 174, 174, 249, 249,
- 249, 176, 176, 176, 174, 176, 174, 232, 227, 17,
- 63, 65, 82, 114, 117, 118, 121, 138, 150, 164,
- 192, 282, 242, 169, 289, 192, 242, 242, 242, 192,
- 192, 175, 242, 242, 242, 244, 245, 212, 15, 237,
- 179, 289, 177, 261, 182, 82, 254, 292, 193, 174,
- 165, 165, 247, 165, 15, 174, 284, 165, 174, 282,
- 282, 282, 282, 249, 280, 282, 176, 15, 157, 16,
- 17, 18, 19, 20, 21, 22, 23, 24, 34, 161,
- 162, 163, 164, 165, 166, 167, 168, 169, 170, 171,
- 173, 174, 175, 52, 282, 249, 192, 289, 290, 289,
- 192, 191, 176, 188, 156, 289, 289, 289, 289, 289,
- 289, 289, 182, 289, 282, 165, 10, 11, 206, 246,
- 248, 289, 289, 158, 192, 174, 174, 63, 244, 187,
- 289, 197, 156, 158, 160, 234, 158, 196, 280, 280,
- 176, 176, 176, 280, 280, 176, 282, 174, 34, 225,
- 292, 192, 192, 242, 242, 242, 278, 176, 176, 176,
- 13, 17, 63, 127, 150, 164, 169, 174, 240, 290,
- 292, 13, 15, 17, 63, 127, 150, 164, 169, 174,
- 241, 192, 192, 192, 177, 159, 255, 256, 292, 49,
- 249, 249, 249, 174, 249, 174, 249, 249, 249, 282,
- 176, 176, 15, 238, 282, 282, 282, 282, 282, 282,
- 282, 282, 282, 282, 282, 282, 282, 282, 282, 282,
- 282, 282, 282, 282, 282, 289, 176, 280, 282, 176,
- 176, 176, 159, 191, 182, 156, 157, 157, 157, 157,
- 157, 157, 177, 156, 157, 176, 10, 11, 12, 62,
- 63, 143, 150, 217, 218, 219, 220, 221, 270, 292,
- 174, 234, 200, 158, 158, 160, 203, 10, 13, 169,
- 205, 244, 13, 17, 63, 127, 150, 164, 169, 239,
- 290, 292, 182, 174, 156, 158, 159, 160, 233, 274,
- 275, 69, 70, 156, 282, 13, 17, 63, 120, 150,
- 164, 169, 174, 198, 222, 224, 290, 176, 176, 176,
- 176, 212, 176, 176, 289, 63, 247, 156, 242, 179,
- 174, 174, 174, 169, 192, 240, 240, 240, 192, 192,
- 240, 175, 232, 192, 169, 289, 192, 241, 241, 241,
- 192, 192, 241, 175, 232, 225, 157, 160, 122, 123,
- 124, 143, 148, 257, 288, 289, 156, 157, 192, 176,
- 166, 166, 279, 166, 289, 176, 166, 176, 176, 282,
- 159, 176, 179, 261, 177, 268, 10, 10, 10, 10,
- 10, 10, 267, 291, 158, 221, 221, 166, 157, 15,
- 289, 13, 17, 63, 127, 150, 164, 169, 174, 240,
- 241, 201, 224, 249, 227, 176, 169, 222, 227, 239,
- 169, 192, 239, 239, 239, 192, 192, 174, 175, 192,
- 177, 207, 274, 184, 185, 289, 69, 70, 177, 276,
- 292, 158, 158, 156, 235, 236, 282, 292, 158, 169,
- 192, 222, 6, 16, 17, 18, 19, 20, 21, 22,
- 23, 24, 34, 36, 37, 38, 39, 40, 41, 42,
- 43, 44, 45, 46, 47, 70, 116, 157, 160, 162,
- 163, 164, 165, 166, 167, 168, 169, 170, 171, 172,
- 174, 175, 178, 213, 222, 192, 192, 222, 159, 174,
- 175, 225, 160, 232, 234, 192, 192, 15, 176, 247,
- 243, 274, 192, 227, 227, 227, 192, 240, 240, 240,
- 176, 278, 192, 192, 241, 241, 241, 176, 278, 282,
- 148, 288, 148, 288, 148, 288, 289, 122, 123, 124,
- 15, 182, 257, 174, 174, 176, 174, 176, 174, 282,
- 182, 157, 157, 176, 157, 226, 292, 157, 157, 157,
- 182, 176, 240, 241, 240, 241, 189, 195, 214, 215,
- 220, 289, 160, 169, 192, 192, 192, 160, 231, 292,
- 232, 234, 158, 176, 174, 222, 176, 176, 174, 192,
- 239, 239, 239, 210, 278, 227, 177, 156, 157, 156,
- 174, 158, 158, 3, 4, 5, 6, 7, 8, 9,
- 10, 11, 12, 13, 15, 16, 17, 18, 19, 20,
- 21, 22, 23, 24, 25, 26, 34, 35, 36, 37,
- 38, 39, 40, 41, 42, 43, 44, 45, 46, 47,
- 48, 49, 50, 51, 52, 55, 56, 57, 58, 59,
- 60, 61, 62, 63, 64, 65, 66, 67, 68, 69,
- 70, 71, 72, 73, 75, 77, 78, 79, 80, 81,
- 82, 83, 84, 85, 86, 88, 89, 90, 107, 114,
- 115, 116, 117, 118, 119, 120, 121, 122, 123, 124,
- 125, 126, 127, 128, 129, 130, 131, 132, 133, 134,
- 135, 136, 137, 138, 139, 140, 141, 142, 143, 144,
- 145, 146, 147, 148, 149, 150, 151, 152, 156, 157,
- 158, 159, 160, 161, 162, 163, 164, 165, 166, 167,
- 168, 169, 170, 171, 172, 173, 174, 175, 176, 178,
- 179, 277, 235, 177, 157, 192, 222, 10, 176, 179,
- 192, 222, 222, 176, 282, 223, 278, 282, 157, 225,
- 176, 243, 177, 176, 176, 176, 240, 174, 179, 241,
- 174, 179, 157, 288, 288, 288, 288, 288, 288, 177,
- 280, 280, 280, 280, 177, 10, 10, 158, 10, 176,
- 10, 10, 10, 177, 158, 231, 231, 249, 192, 51,
- 67, 72, 126, 131, 134, 164, 167, 168, 169, 172,
- 174, 178, 281, 283, 157, 212, 204, 176, 174, 212,
- 211, 239, 227, 179, 176, 274, 185, 279, 279, 276,
- 177, 156, 282, 222, 192, 229, 179, 198, 156, 212,
- 212, 212, 227, 192, 227, 192, 176, 176, 176, 176,
- 176, 157, 176, 157, 158, 157, 176, 176, 157, 176,
- 174, 165, 165, 165, 15, 174, 281, 165, 281, 281,
- 281, 281, 281, 249, 280, 281, 16, 17, 18, 19,
- 20, 21, 22, 23, 24, 34, 161, 162, 163, 164,
- 167, 168, 169, 170, 171, 173, 174, 175, 201, 192,
- 227, 174, 208, 192, 227, 176, 192, 212, 177, 177,
- 176, 177, 235, 176, 192, 274, 192, 192, 192, 176,
- 176, 158, 10, 158, 10, 10, 158, 158, 10, 158,
- 249, 249, 249, 249, 174, 249, 249, 176, 176, 281,
- 281, 281, 281, 281, 281, 281, 281, 281, 281, 281,
- 281, 281, 281, 281, 281, 281, 281, 281, 289, 176,
- 280, 282, 176, 209, 227, 176, 212, 192, 15, 177,
- 212, 177, 225, 225, 225, 212, 212, 157, 226, 176,
- 157, 157, 176, 176, 166, 166, 166, 289, 176, 166,
- 281, 159, 176, 179, 212, 227, 176, 212, 192, 192,
- 192, 10, 176, 158, 10, 10, 158, 174, 174, 174,
- 176, 174, 281, 192, 176, 212, 158, 176, 157, 176,
- 280, 280, 280, 280, 212, 192, 158, 10, 158, 176,
- 176, 176, 176, 192, 225, 176, 225, 158
-};
-
-/* YYR1[RULE-NUM] -- Symbol kind of the left-hand side of rule RULE-NUM. */
-static const yytype_int16 yyr1[] =
-{
- 0, 180, 181, 181, 181, 182, 182, 183, 182, 184,
- 184, 185, 185, 185, 187, 186, 188, 188, 188, 188,
- 188, 188, 188, 188, 188, 188, 188, 188, 188, 188,
- 188, 188, 188, 188, 188, 188, 188, 188, 188, 188,
- 188, 188, 188, 190, 189, 191, 191, 191, 191, 191,
- 191, 191, 191, 191, 191, 191, 191, 191, 191, 191,
- 191, 191, 191, 192, 192, 192, 192, 192, 193, 193,
- 194, 194, 196, 195, 195, 197, 195, 195, 195, 198,
- 198, 200, 199, 199, 201, 201, 203, 202, 204, 202,
- 205, 202, 207, 206, 208, 206, 209, 206, 210, 206,
- 211, 206, 206, 212, 212, 212, 212, 212, 212, 212,
- 212, 212, 212, 212, 212, 212, 212, 213, 213, 213,
- 213, 213, 213, 213, 213, 213, 213, 213, 213, 213,
- 213, 213, 213, 213, 213, 213, 213, 213, 213, 213,
- 213, 213, 213, 213, 213, 213, 213, 213, 213, 213,
- 213, 213, 213, 213, 213, 213, 213, 214, 214, 214,
- 215, 216, 215, 215, 215, 217, 217, 218, 218, 219,
- 219, 220, 220, 220, 220, 220, 220, 220, 220, 220,
- 220, 220, 221, 221, 221, 221, 222, 222, 222, 222,
- 222, 222, 222, 222, 222, 222, 222, 223, 222, 224,
- 224, 225, 225, 225, 226, 226, 227, 227, 227, 227,
- 227, 228, 228, 229, 229, 229, 229, 229, 230, 230,
- 231, 231, 232, 232, 233, 233, 233, 233, 233, 234,
- 234, 234, 234, 234, 234, 235, 235, 235, 236, 236,
- 236, 236, 237, 237, 238, 238, 239, 239, 239, 239,
- 239, 239, 239, 239, 239, 239, 240, 240, 240, 240,
- 240, 240, 240, 240, 240, 240, 240, 240, 241, 241,
- 241, 241, 241, 241, 241, 241, 241, 241, 241, 241,
- 242, 242, 242, 242, 242, 242, 242, 242, 242, 242,
- 242, 243, 243, 243, 243, 243, 243, 243, 243, 243,
- 243, 243, 243, 243, 243, 243, 244, 244, 244, 244,
- 244, 244, 244, 244, 244, 244, 244, 244, 244, 245,
- 246, 246, 246, 246, 246, 246, 246, 246, 246, 246,
- 246, 246, 246, 246, 247, 247, 247, 247, 247, 247,
- 247, 247, 247, 248, 248, 249, 249, 249, 249, 251,
- 250, 253, 252, 254, 254, 255, 255, 256, 256, 257,
- 257, 257, 257, 257, 257, 257, 257, 257, 257, 259,
- 258, 260, 260, 260, 260, 261, 261, 262, 262, 262,
- 263, 263, 263, 264, 264, 264, 265, 265, 265, 267,
- 266, 268, 266, 266, 266, 269, 269, 269, 269, 270,
- 270, 270, 271, 271, 271, 271, 271, 271, 271, 271,
- 271, 271, 271, 271, 271, 271, 271, 272, 272, 272,
- 273, 275, 274, 276, 276, 277, 277, 277, 277, 277,
- 277, 277, 277, 277, 277, 277, 277, 277, 277, 277,
- 277, 277, 277, 277, 277, 277, 277, 277, 277, 277,
- 277, 277, 277, 277, 277, 277, 277, 277, 277, 277,
- 277, 277, 277, 277, 277, 277, 277, 277, 277, 277,
- 277, 277, 277, 277, 277, 277, 277, 277, 277, 277,
- 277, 277, 277, 277, 277, 277, 277, 277, 277, 277,
- 277, 277, 277, 277, 277, 277, 277, 277, 277, 277,
- 277, 277, 277, 277, 277, 277, 277, 277, 277, 277,
- 277, 277, 277, 277, 277, 277, 277, 277, 277, 277,
- 277, 277, 277, 277, 277, 277, 277, 277, 277, 277,
- 277, 277, 277, 277, 277, 277, 277, 277, 277, 277,
- 277, 277, 277, 277, 277, 277, 277, 277, 277, 277,
- 277, 277, 277, 277, 277, 277, 277, 277, 277, 277,
- 277, 277, 277, 278, 278, 279, 279, 280, 280, 281,
- 281, 281, 281, 281, 281, 281, 281, 281, 281, 281,
- 281, 281, 281, 281, 281, 281, 281, 281, 281, 281,
- 281, 281, 281, 281, 281, 281, 281, 281, 281, 281,
- 281, 281, 281, 281, 281, 281, 281, 281, 281, 282,
- 282, 282, 282, 282, 282, 282, 282, 282, 282, 282,
- 282, 282, 282, 282, 282, 282, 282, 282, 282, 282,
- 282, 282, 282, 282, 282, 282, 282, 282, 282, 282,
- 282, 282, 282, 282, 282, 282, 282, 282, 282, 282,
- 282, 282, 282, 282, 282, 282, 282, 282, 282, 282,
- 282, 282, 282, 282, 282, 282, 282, 282, 282, 282,
- 282, 283, 283, 283, 283, 283, 283, 283, 283, 283,
- 283, 283, 283, 283, 283, 283, 283, 283, 283, 283,
- 283, 283, 283, 283, 283, 283, 283, 283, 283, 283,
- 283, 283, 284, 284, 284, 284, 284, 284, 284, 284,
- 284, 284, 284, 284, 284, 284, 284, 284, 284, 284,
- 284, 284, 284, 284, 284, 284, 284, 284, 284, 284,
- 284, 284, 284, 284, 284, 284, 284, 284, 284, 284,
- 284, 284, 284, 284, 284, 284, 284, 285, 285, 285,
- 285, 285, 285, 285, 285, 285, 285, 285, 286, 286,
- 286, 286, 286, 287, 287, 287, 287, 288, 288, 288,
- 289, 289, 289, 289, 289, 289, 289, 289, 289, 289,
- 289, 290, 290, 290, 290, 291, 291, 291, 291, 292
-};
-
-/* YYR2[RULE-NUM] -- Number of symbols on the right-hand side of rule RULE-NUM. */
-static const yytype_int8 yyr2[] =
-{
- 0, 2, 2, 2, 2, 1, 3, 0, 4, 1,
- 3, 4, 5, 4, 0, 5, 1, 1, 1, 1,
- 1, 2, 1, 1, 2, 2, 2, 2, 8, 11,
- 9, 11, 13, 15, 7, 9, 12, 9, 9, 13,
- 9, 7, 5, 0, 3, 1, 2, 2, 3, 2,
- 2, 2, 2, 4, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 1, 4, 7, 5, 5, 1, 3,
- 1, 4, 0, 4, 3, 0, 4, 3, 1, 2,
- 4, 0, 4, 3, 2, 4, 0, 7, 0, 10,
- 0, 7, 0, 8, 0, 12, 0, 13, 0, 8,
- 0, 9, 1, 1, 2, 2, 2, 4, 2, 2,
- 2, 2, 2, 2, 4, 5, 6, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 2, 2, 1, 1, 1, 1, 1,
- 2, 0, 6, 2, 2, 1, 1, 1, 3, 1,
- 1, 1, 2, 4, 2, 3, 3, 4, 2, 3,
- 4, 3, 1, 1, 1, 1, 2, 3, 4, 2,
- 2, 3, 3, 3, 4, 5, 3, 0, 7, 2,
- 3, 1, 3, 4, 1, 2, 1, 1, 1, 3,
- 2, 1, 3, 1, 1, 1, 3, 2, 1, 3,
- 1, 2, 1, 2, 1, 3, 5, 3, 3, 1,
- 3, 3, 3, 3, 4, 1, 1, 2, 1, 3,
- 3, 5, 5, 5, 1, 1, 1, 2, 2, 2,
- 2, 3, 3, 3, 4, 5, 1, 2, 2, 2,
- 2, 3, 3, 3, 4, 5, 8, 3, 1, 3,
- 2, 2, 2, 3, 3, 3, 4, 5, 8, 3,
- 1, 1, 3, 2, 2, 2, 3, 3, 3, 4,
- 5, 1, 1, 3, 2, 2, 2, 3, 3, 3,
- 4, 5, 6, 11, 11, 11, 1, 1, 2, 1,
- 1, 1, 3, 5, 4, 4, 4, 1, 1, 1,
- 1, 1, 2, 1, 1, 1, 3, 5, 3, 4,
- 4, 4, 1, 1, 1, 1, 2, 3, 3, 4,
- 4, 1, 1, 1, 1, 2, 3, 2, 3, 0,
- 6, 0, 9, 1, 1, 1, 1, 2, 3, 1,
- 2, 2, 2, 3, 3, 3, 3, 3, 3, 0,
- 5, 4, 2, 5, 3, 1, 1, 1, 4, 6,
- 1, 3, 5, 1, 2, 2, 1, 1, 1, 0,
- 7, 0, 7, 4, 5, 3, 6, 4, 4, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 2, 2, 2, 2, 1, 1, 2,
- 1, 0, 2, 1, 2, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 3, 1, 1, 1, 1, 1, 3, 1,
- 4, 7, 7, 7, 7, 4, 2, 5, 4, 2,
- 2, 2, 2, 2, 2, 3, 3, 3, 3, 3,
- 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
- 3, 3, 5, 4, 4, 3, 3, 3, 3, 1,
- 4, 7, 7, 7, 7, 4, 4, 4, 4, 4,
- 4, 4, 4, 4, 4, 4, 4, 4, 4, 4,
- 4, 2, 5, 4, 2, 5, 4, 4, 2, 2,
- 2, 2, 2, 2, 3, 3, 3, 3, 3, 3,
- 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
- 3, 3, 3, 5, 4, 4, 3, 3, 3, 3,
- 3, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 9, 12, 4, 4, 6, 4, 4, 6,
- 6, 4, 4, 4, 4, 4, 4, 4, 4, 4,
- 4, 4, 1, 4, 7, 7, 7, 7, 4, 2,
- 5, 4, 2, 5, 4, 4, 2, 2, 2, 2,
- 2, 3, 3, 3, 3, 3, 3, 3, 3, 3,
- 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
- 5, 4, 4, 3, 3, 3, 3, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 2, 4, 2, 3, 1, 2, 1, 2, 2,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 2, 2, 0
-};
-
-
-enum { YYENOMEM = -2 };
-
-#define yyerrok (yyerrstatus = 0)
-#define yyclearin (yychar = YYEMPTY)
-
-#define YYACCEPT goto yyacceptlab
-#define YYABORT goto yyabortlab
-#define YYERROR goto yyerrorlab
-#define YYNOMEM goto yyexhaustedlab
-
-
-#define YYRECOVERING() (!!yyerrstatus)
-
-#define YYBACKUP(Token, Value) \
- do \
- if (yychar == YYEMPTY) \
- { \
- yychar = (Token); \
- yylval = (Value); \
- YYPOPSTACK (yylen); \
- yystate = *yyssp; \
- goto yybackup; \
- } \
- else \
- { \
- yyerror (&yylloc, YY_("syntax error: cannot back up")); \
- YYERROR; \
- } \
- while (0)
-
-/* Backward compatibility with an undocumented macro.
- Use YYerror or YYUNDEF. */
-#define YYERRCODE YYUNDEF
-
-/* YYLLOC_DEFAULT -- Set CURRENT to span from RHS[1] to RHS[N].
- If N is 0, then set CURRENT to the empty location which ends
- the previous symbol: RHS[0] (always defined). */
-
-#ifndef YYLLOC_DEFAULT
-# define YYLLOC_DEFAULT(Current, Rhs, N) \
- do \
- if (N) \
- { \
- (Current).first_line = YYRHSLOC (Rhs, 1).first_line; \
- (Current).first_column = YYRHSLOC (Rhs, 1).first_column; \
- (Current).last_line = YYRHSLOC (Rhs, N).last_line; \
- (Current).last_column = YYRHSLOC (Rhs, N).last_column; \
- } \
- else \
- { \
- (Current).first_line = (Current).last_line = \
- YYRHSLOC (Rhs, 0).last_line; \
- (Current).first_column = (Current).last_column = \
- YYRHSLOC (Rhs, 0).last_column; \
- } \
- while (0)
-#endif
-
-#define YYRHSLOC(Rhs, K) ((Rhs)[K])
-
-
-/* Enable debugging if requested. */
-#if YYDEBUG
-
-# ifndef YYFPRINTF
-# include /* INFRINGES ON USER NAME SPACE */
-# define YYFPRINTF fprintf
-# endif
-
-# define YYDPRINTF(Args) \
-do { \
- if (yydebug) \
- YYFPRINTF Args; \
-} while (0)
-
-
-/* YYLOCATION_PRINT -- Print the location on the stream.
- This macro was not mandated originally: define only if we know
- we won't break user code: when these are the locations we know. */
-
-# ifndef YYLOCATION_PRINT
-
-# if defined YY_LOCATION_PRINT
-
- /* Temporary convenience wrapper in case some people defined the
- undocumented and private YY_LOCATION_PRINT macros. */
-# define YYLOCATION_PRINT(File, Loc) YY_LOCATION_PRINT(File, *(Loc))
-
-# elif defined YYLTYPE_IS_TRIVIAL && YYLTYPE_IS_TRIVIAL
-
-/* Print *YYLOCP on YYO. Private, do not rely on its existence. */
-
-YY_ATTRIBUTE_UNUSED
-static int
-yy_location_print_ (FILE *yyo, YYLTYPE const * const yylocp)
-{
- int res = 0;
- int end_col = 0 != yylocp->last_column ? yylocp->last_column - 1 : 0;
- if (0 <= yylocp->first_line)
- {
- res += YYFPRINTF (yyo, "%d", yylocp->first_line);
- if (0 <= yylocp->first_column)
- res += YYFPRINTF (yyo, ".%d", yylocp->first_column);
- }
- if (0 <= yylocp->last_line)
- {
- if (yylocp->first_line < yylocp->last_line)
- {
- res += YYFPRINTF (yyo, "-%d", yylocp->last_line);
- if (0 <= end_col)
- res += YYFPRINTF (yyo, ".%d", end_col);
- }
- else if (0 <= end_col && yylocp->first_column < end_col)
- res += YYFPRINTF (yyo, "-%d", end_col);
- }
- return res;
-}
-
-# define YYLOCATION_PRINT yy_location_print_
-
- /* Temporary convenience wrapper in case some people defined the
- undocumented and private YY_LOCATION_PRINT macros. */
-# define YY_LOCATION_PRINT(File, Loc) YYLOCATION_PRINT(File, &(Loc))
-
-# else
-
-# define YYLOCATION_PRINT(File, Loc) ((void) 0)
- /* Temporary convenience wrapper in case some people defined the
- undocumented and private YY_LOCATION_PRINT macros. */
-# define YY_LOCATION_PRINT YYLOCATION_PRINT
-
-# endif
-# endif /* !defined YYLOCATION_PRINT */
-
-
-# define YY_SYMBOL_PRINT(Title, Kind, Value, Location) \
-do { \
- if (yydebug) \
- { \
- YYFPRINTF (stderr, "%s ", Title); \
- yy_symbol_print (stderr, \
- Kind, Value, Location); \
- YYFPRINTF (stderr, "\n"); \
- } \
-} while (0)
-
-
-/*-----------------------------------.
-| Print this symbol's value on YYO. |
-`-----------------------------------*/
-
-static void
-yy_symbol_value_print (FILE *yyo,
- yysymbol_kind_t yykind, YYSTYPE const * const yyvaluep, YYLTYPE const * const yylocationp)
-{
- FILE *yyoutput = yyo;
- YY_USE (yyoutput);
- YY_USE (yylocationp);
- if (!yyvaluep)
- return;
- YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
- YY_USE (yykind);
- YY_IGNORE_MAYBE_UNINITIALIZED_END
-}
-
-
-/*---------------------------.
-| Print this symbol on YYO. |
-`---------------------------*/
-
-static void
-yy_symbol_print (FILE *yyo,
- yysymbol_kind_t yykind, YYSTYPE const * const yyvaluep, YYLTYPE const * const yylocationp)
-{
- YYFPRINTF (yyo, "%s %s (",
- yykind < YYNTOKENS ? "token" : "nterm", yysymbol_name (yykind));
-
- YYLOCATION_PRINT (yyo, yylocationp);
- YYFPRINTF (yyo, ": ");
- yy_symbol_value_print (yyo, yykind, yyvaluep, yylocationp);
- YYFPRINTF (yyo, ")");
-}
-
-/*------------------------------------------------------------------.
-| yy_stack_print -- Print the state stack from its BOTTOM up to its |
-| TOP (included). |
-`------------------------------------------------------------------*/
-
-static void
-yy_stack_print (yy_state_t *yybottom, yy_state_t *yytop)
-{
- YYFPRINTF (stderr, "Stack now");
- for (; yybottom <= yytop; yybottom++)
- {
- int yybot = *yybottom;
- YYFPRINTF (stderr, " %d", yybot);
- }
- YYFPRINTF (stderr, "\n");
-}
-
-# define YY_STACK_PRINT(Bottom, Top) \
-do { \
- if (yydebug) \
- yy_stack_print ((Bottom), (Top)); \
-} while (0)
-
-
-/*------------------------------------------------.
-| Report that the YYRULE is going to be reduced. |
-`------------------------------------------------*/
-
-static void
-yy_reduce_print (yy_state_t *yyssp, YYSTYPE *yyvsp, YYLTYPE *yylsp,
- int yyrule)
-{
- int yylno = yyrline[yyrule];
- int yynrhs = yyr2[yyrule];
- int yyi;
- YYFPRINTF (stderr, "Reducing stack by rule %d (line %d):\n",
- yyrule - 1, yylno);
- /* The symbols being reduced. */
- for (yyi = 0; yyi < yynrhs; yyi++)
- {
- YYFPRINTF (stderr, " $%d = ", yyi + 1);
- yy_symbol_print (stderr,
- YY_ACCESSING_SYMBOL (+yyssp[yyi + 1 - yynrhs]),
- &yyvsp[(yyi + 1) - (yynrhs)],
- &(yylsp[(yyi + 1) - (yynrhs)]));
- YYFPRINTF (stderr, "\n");
- }
-}
-
-# define YY_REDUCE_PRINT(Rule) \
-do { \
- if (yydebug) \
- yy_reduce_print (yyssp, yyvsp, yylsp, Rule); \
-} while (0)
-
-/* Nonzero means print parse trace. It is left uninitialized so that
- multiple parsers can coexist. */
-int yydebug;
-#else /* !YYDEBUG */
-# define YYDPRINTF(Args) ((void) 0)
-# define YY_SYMBOL_PRINT(Title, Kind, Value, Location)
-# define YY_STACK_PRINT(Bottom, Top)
-# define YY_REDUCE_PRINT(Rule)
-#endif /* !YYDEBUG */
-
-
-/* YYINITDEPTH -- initial size of the parser's stacks. */
-#ifndef YYINITDEPTH
-# define YYINITDEPTH 200
-#endif
-
-/* YYMAXDEPTH -- maximum size the stacks can grow to (effective only
- if the built-in stack extension method is used).
-
- Do not make this value too large; the results are undefined if
- YYSTACK_ALLOC_MAXIMUM < YYSTACK_BYTES (YYMAXDEPTH)
- evaluated with infinite-precision integer arithmetic. */
-
-#ifndef YYMAXDEPTH
-# define YYMAXDEPTH 10000
-#endif
-
-
-
-
-
-
-/*-----------------------------------------------.
-| Release the memory associated to this symbol. |
-`-----------------------------------------------*/
-
-static void
-yydestruct (const char *yymsg,
- yysymbol_kind_t yykind, YYSTYPE *yyvaluep, YYLTYPE *yylocationp)
-{
- YY_USE (yyvaluep);
- YY_USE (yylocationp);
- if (!yymsg)
- yymsg = "Deleting";
- YY_SYMBOL_PRINT (yymsg, yykind, yyvaluep, yylocationp);
-
- YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
- YY_USE (yykind);
- YY_IGNORE_MAYBE_UNINITIALIZED_END
-}
-
-
-
-
-
-
-/*----------.
-| yyparse. |
-`----------*/
-
-int
-yyparse (void)
-{
-/* Lookahead token kind. */
-int yychar;
-
-
-/* The semantic value of the lookahead symbol. */
-/* Default value used for initialization, for pacifying older GCCs
- or non-GCC compilers. */
-YY_INITIAL_VALUE (static YYSTYPE yyval_default;)
-YYSTYPE yylval YY_INITIAL_VALUE (= yyval_default);
-
-/* Location data for the lookahead symbol. */
-static YYLTYPE yyloc_default
-# if defined YYLTYPE_IS_TRIVIAL && YYLTYPE_IS_TRIVIAL
- = { 1, 1, 1, 1 }
-# endif
-;
-YYLTYPE yylloc = yyloc_default;
-
- /* Number of syntax errors so far. */
- int yynerrs = 0;
-
- yy_state_fast_t yystate = 0;
- /* Number of tokens to shift before error messages enabled. */
- int yyerrstatus = 0;
-
- /* Refer to the stacks through separate pointers, to allow yyoverflow
- to reallocate them elsewhere. */
-
- /* Their size. */
- YYPTRDIFF_T yystacksize = YYINITDEPTH;
-
- /* The state stack: array, bottom, top. */
- yy_state_t yyssa[YYINITDEPTH];
- yy_state_t *yyss = yyssa;
- yy_state_t *yyssp = yyss;
-
- /* The semantic value stack: array, bottom, top. */
- YYSTYPE yyvsa[YYINITDEPTH];
- YYSTYPE *yyvs = yyvsa;
- YYSTYPE *yyvsp = yyvs;
-
- /* The location stack: array, bottom, top. */
- YYLTYPE yylsa[YYINITDEPTH];
- YYLTYPE *yyls = yylsa;
- YYLTYPE *yylsp = yyls;
-
- int yyn;
- /* The return value of yyparse. */
- int yyresult;
- /* Lookahead symbol kind. */
- yysymbol_kind_t yytoken = YYSYMBOL_YYEMPTY;
- /* The variables used to return semantic value and location from the
- action routines. */
- YYSTYPE yyval;
- YYLTYPE yyloc;
-
- /* The locations where the error started and ended. */
- YYLTYPE yyerror_range[3];
-
-
-
-#define YYPOPSTACK(N) (yyvsp -= (N), yyssp -= (N), yylsp -= (N))
-
- /* The number of symbols on the RHS of the reduced rule.
- Keep to zero when no symbol should be popped. */
- int yylen = 0;
-
- YYDPRINTF ((stderr, "Starting parse\n"));
-
- yychar = YYEMPTY; /* Cause a token to be read. */
-
- yylsp[0] = yylloc;
- goto yysetstate;
-
-
-/*------------------------------------------------------------.
-| yynewstate -- push a new state, which is found in yystate. |
-`------------------------------------------------------------*/
-yynewstate:
- /* In all cases, when you get here, the value and location stacks
- have just been pushed. So pushing a state here evens the stacks. */
- yyssp++;
-
-
-/*--------------------------------------------------------------------.
-| yysetstate -- set current state (the top of the stack) to yystate. |
-`--------------------------------------------------------------------*/
-yysetstate:
- YYDPRINTF ((stderr, "Entering state %d\n", yystate));
- YY_ASSERT (0 <= yystate && yystate < YYNSTATES);
- YY_IGNORE_USELESS_CAST_BEGIN
- *yyssp = YY_CAST (yy_state_t, yystate);
- YY_IGNORE_USELESS_CAST_END
- YY_STACK_PRINT (yyss, yyssp);
-
- if (yyss + yystacksize - 1 <= yyssp)
-#if !defined yyoverflow && !defined YYSTACK_RELOCATE
- YYNOMEM;
-#else
- {
- /* Get the current used size of the three stacks, in elements. */
- YYPTRDIFF_T yysize = yyssp - yyss + 1;
-
-# if defined yyoverflow
- {
- /* Give user a chance to reallocate the stack. Use copies of
- these so that the &'s don't force the real ones into
- memory. */
- yy_state_t *yyss1 = yyss;
- YYSTYPE *yyvs1 = yyvs;
- YYLTYPE *yyls1 = yyls;
-
- /* Each stack pointer address is followed by the size of the
- data in use in that stack, in bytes. This used to be a
- conditional around just the two extra args, but that might
- be undefined if yyoverflow is a macro. */
- yyoverflow (YY_("memory exhausted"),
- &yyss1, yysize * YYSIZEOF (*yyssp),
- &yyvs1, yysize * YYSIZEOF (*yyvsp),
- &yyls1, yysize * YYSIZEOF (*yylsp),
- &yystacksize);
- yyss = yyss1;
- yyvs = yyvs1;
- yyls = yyls1;
- }
-# else /* defined YYSTACK_RELOCATE */
- /* Extend the stack our own way. */
- if (YYMAXDEPTH <= yystacksize)
- YYNOMEM;
- yystacksize *= 2;
- if (YYMAXDEPTH < yystacksize)
- yystacksize = YYMAXDEPTH;
-
- {
- yy_state_t *yyss1 = yyss;
- union yyalloc *yyptr =
- YY_CAST (union yyalloc *,
- YYSTACK_ALLOC (YY_CAST (YYSIZE_T, YYSTACK_BYTES (yystacksize))));
- if (! yyptr)
- YYNOMEM;
- YYSTACK_RELOCATE (yyss_alloc, yyss);
- YYSTACK_RELOCATE (yyvs_alloc, yyvs);
- YYSTACK_RELOCATE (yyls_alloc, yyls);
-# undef YYSTACK_RELOCATE
- if (yyss1 != yyssa)
- YYSTACK_FREE (yyss1);
- }
-# endif
-
- yyssp = yyss + yysize - 1;
- yyvsp = yyvs + yysize - 1;
- yylsp = yyls + yysize - 1;
-
- YY_IGNORE_USELESS_CAST_BEGIN
- YYDPRINTF ((stderr, "Stack size increased to %ld\n",
- YY_CAST (long, yystacksize)));
- YY_IGNORE_USELESS_CAST_END
-
- if (yyss + yystacksize - 1 <= yyssp)
- YYABORT;
- }
-#endif /* !defined yyoverflow && !defined YYSTACK_RELOCATE */
-
-
- if (yystate == YYFINAL)
- YYACCEPT;
-
- goto yybackup;
-
-
-/*-----------.
-| yybackup. |
-`-----------*/
-yybackup:
- /* Do appropriate processing given the current state. Read a
- lookahead token if we need one and don't already have one. */
-
- /* First try to decide what to do without reference to lookahead token. */
- yyn = yypact[yystate];
- if (yypact_value_is_default (yyn))
- goto yydefault;
-
- /* Not known => get a lookahead token if don't already have one. */
-
- /* YYCHAR is either empty, or end-of-input, or a valid lookahead. */
- if (yychar == YYEMPTY)
- {
- YYDPRINTF ((stderr, "Reading a token\n"));
- yychar = yylex (&yylval, &yylloc);
- }
-
- if (yychar <= YYEOF)
- {
- yychar = YYEOF;
- yytoken = YYSYMBOL_YYEOF;
- YYDPRINTF ((stderr, "Now at end of input.\n"));
- }
- else if (yychar == YYerror)
- {
- /* The scanner already issued an error message, process directly
- to error recovery. But do not keep the error token as
- lookahead, it is too special and may lead us to an endless
- loop in error recovery. */
- yychar = YYUNDEF;
- yytoken = YYSYMBOL_YYerror;
- yyerror_range[1] = yylloc;
- goto yyerrlab1;
- }
- else
- {
- yytoken = YYTRANSLATE (yychar);
- YY_SYMBOL_PRINT ("Next token is", yytoken, &yylval, &yylloc);
- }
-
- /* If the proper action on seeing token YYTOKEN is to reduce or to
- detect an error, take that action. */
- yyn += yytoken;
- if (yyn < 0 || YYLAST < yyn || yycheck[yyn] != yytoken)
- goto yydefault;
- yyn = yytable[yyn];
- if (yyn <= 0)
- {
- if (yytable_value_is_error (yyn))
- goto yyerrlab;
- yyn = -yyn;
- goto yyreduce;
- }
-
- /* Count tokens shifted since error; after three, turn off error
- status. */
- if (yyerrstatus)
- yyerrstatus--;
-
- /* Shift the lookahead token. */
- YY_SYMBOL_PRINT ("Shifting", yytoken, &yylval, &yylloc);
- yystate = yyn;
- YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
- *++yyvsp = yylval;
- YY_IGNORE_MAYBE_UNINITIALIZED_END
- *++yylsp = yylloc;
-
- /* Discard the shifted token. */
- yychar = YYEMPTY;
- goto yynewstate;
-
-
-/*-----------------------------------------------------------.
-| yydefault -- do the default action for the current state. |
-`-----------------------------------------------------------*/
-yydefault:
- yyn = yydefact[yystate];
- if (yyn == 0)
- goto yyerrlab;
- goto yyreduce;
-
-
-/*-----------------------------.
-| yyreduce -- do a reduction. |
-`-----------------------------*/
-yyreduce:
- /* yyn is the number of a rule to reduce with. */
- yylen = yyr2[yyn];
-
- /* If YYLEN is nonzero, implement the default value of the action:
- '$$ = $1'.
-
- Otherwise, the following line sets YYVAL to garbage.
- This behavior is undocumented and Bison
- users should not rely upon it. Assigning to YYVAL
- unconditionally makes the parser a bit smaller, and it avoids a
- GCC warning that YYVAL may be used uninitialized. */
- yyval = yyvsp[1-yylen];
-
- /* Default location. */
- YYLLOC_DEFAULT (yyloc, (yylsp - yylen), yylen);
- yyerror_range[1] = yyloc;
- YY_REDUCE_PRINT (yyn);
- switch (yyn)
- {
- case 3: /* grammar: START_CONST_EXPR const_expr */
-#line 468 "dtool/src/cppparser/cppBison.yxx"
-{
- current_expr = (yyvsp[0].u.expr);
-}
-#line 3882 "built/tmp/cppBison.yxx.c"
- break;
-
- case 4: /* grammar: START_TYPE full_type */
-#line 472 "dtool/src/cppparser/cppBison.yxx"
-{
- current_type = (yyvsp[0].u.type);
-}
-#line 3890 "built/tmp/cppBison.yxx.c"
- break;
-
- case 6: /* cpp: cpp optional_attributes ';' */
-#line 480 "dtool/src/cppparser/cppBison.yxx"
-{
- if (!(yyvsp[-1].attr_list).is_empty()) {
- current_scope->add_declaration(new CPPDeclaration((yylsp[-1]).file, (yyvsp[-1].attr_list)), global_scope, current_lexer, (yylsp[-1]));
- }
-}
-#line 3900 "built/tmp/cppBison.yxx.c"
- break;
-
- case 7: /* $@1: %empty */
-#line 486 "dtool/src/cppparser/cppBison.yxx"
-{
- current_attributes = (yyvsp[0].attr_list);
-}
-#line 3908 "built/tmp/cppBison.yxx.c"
- break;
-
- case 8: /* cpp: cpp optional_attributes $@1 declaration */
-#line 490 "dtool/src/cppparser/cppBison.yxx"
-{
- current_attributes = CPPAttributeList();
-}
-#line 3916 "built/tmp/cppBison.yxx.c"
- break;
-
- case 11: /* constructor_init: name '(' optional_const_expr_comma ')' */
-#line 502 "dtool/src/cppparser/cppBison.yxx"
-{
- delete (yyvsp[-1].u.expr);
-}
-#line 3924 "built/tmp/cppBison.yxx.c"
- break;
-
- case 12: /* constructor_init: name '(' optional_const_expr_comma ')' ELLIPSIS */
-#line 506 "dtool/src/cppparser/cppBison.yxx"
-{
- delete (yyvsp[-2].u.expr);
-}
-#line 3932 "built/tmp/cppBison.yxx.c"
- break;
-
- case 13: /* constructor_init: name '{' optional_const_expr_comma '}' */
-#line 510 "dtool/src/cppparser/cppBison.yxx"
-{
- delete (yyvsp[-1].u.expr);
-}
-#line 3940 "built/tmp/cppBison.yxx.c"
- break;
-
- case 14: /* $@2: %empty */
-#line 522 "dtool/src/cppparser/cppBison.yxx"
-{
- push_storage_class((current_storage_class & ~CPPInstance::SC_c_binding) |
- ((yyvsp[-1].u.integer) & CPPInstance::SC_c_binding));
-}
-#line 3949 "built/tmp/cppBison.yxx.c"
- break;
-
- case 15: /* extern_c: storage_class '{' $@2 cpp '}' */
-#line 527 "dtool/src/cppparser/cppBison.yxx"
-{
- pop_storage_class();
-}
-#line 3957 "built/tmp/cppBison.yxx.c"
- break;
-
- case 22: /* declaration: KW_BEGIN_PUBLISH */
-#line 540 "dtool/src/cppparser/cppBison.yxx"
-{
- if (publish_nest_level != 0) {
- yyerror("Unclosed __begin_publish", publish_loc);
- publish_nest_level = 0;
- current_scope->set_current_vis(V_public);
- }
-
- publish_previous = current_scope->get_current_vis();
- publish_loc = (yylsp[0]);
- publish_nest_level++;
- current_scope->set_current_vis(V_published);
-}
-#line 3974 "built/tmp/cppBison.yxx.c"
- break;
-
- case 23: /* declaration: KW_END_PUBLISH */
-#line 553 "dtool/src/cppparser/cppBison.yxx"
-{
- if (publish_nest_level != 1) {
- yyerror("Unmatched __end_publish", (yylsp[0]));
- } else {
- current_scope->set_current_vis(publish_previous);
- }
- publish_nest_level = 0;
-}
-#line 3987 "built/tmp/cppBison.yxx.c"
- break;
-
- case 24: /* declaration: KW_PUBLISHED ':' */
-#line 562 "dtool/src/cppparser/cppBison.yxx"
-{
- current_scope->set_current_vis(V_published);
-}
-#line 3995 "built/tmp/cppBison.yxx.c"
- break;
-
- case 25: /* declaration: KW_PUBLIC ':' */
-#line 566 "dtool/src/cppparser/cppBison.yxx"
-{
- if (publish_nest_level > 0) {
- current_scope->set_current_vis(V_published);
- } else {
- current_scope->set_current_vis(V_public);
- }
-}
-#line 4007 "built/tmp/cppBison.yxx.c"
- break;
-
- case 26: /* declaration: KW_PROTECTED ':' */
-#line 574 "dtool/src/cppparser/cppBison.yxx"
-{
- current_scope->set_current_vis(V_protected);
-}
-#line 4015 "built/tmp/cppBison.yxx.c"
- break;
-
- case 27: /* declaration: KW_PRIVATE ':' */
-#line 578 "dtool/src/cppparser/cppBison.yxx"
-{
- current_scope->set_current_vis(V_private);
-}
-#line 4023 "built/tmp/cppBison.yxx.c"
- break;
-
- case 28: /* declaration: KW_MAKE_PROPERTY '(' name ',' IDENTIFIER maybe_comma_identifier ')' ';' */
-#line 582 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPDeclaration *getter = (yyvsp[-3].u.identifier)->find_symbol(current_scope, global_scope, current_lexer);
- if (getter == nullptr || getter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("Reference to non-existent or invalid getter: " + (yyvsp[-3].u.identifier)->get_fully_scoped_name(), (yylsp[-3]));
- } else {
- CPPMakeProperty *make_property = new CPPMakeProperty((yyvsp[-5].u.identifier), CPPMakeProperty::T_normal, current_scope, (yylsp[-7]).file);
- make_property->_get_function = getter->as_function_group();
-
- if ((yyvsp[-2].u.identifier) != nullptr) {
- CPPDeclaration *setter = (yyvsp[-2].u.identifier)->find_symbol(current_scope, global_scope, current_lexer);
- if (setter == nullptr || setter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("Reference to non-existent or invalid setter: " + (yyvsp[-2].u.identifier)->get_fully_scoped_name(), (yylsp[-2]));
- } else {
- make_property->_set_function = setter->as_function_group();
- }
- }
-
- current_scope->add_declaration(make_property, global_scope, current_lexer, (yylsp[-7]));
- }
-}
-#line 4048 "built/tmp/cppBison.yxx.c"
- break;
-
- case 29: /* declaration: KW_MAKE_PROPERTY '(' name ',' IDENTIFIER ',' IDENTIFIER ',' IDENTIFIER ')' ';' */
-#line 603 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPDeclaration *getter = (yyvsp[-6].u.identifier)->find_symbol(current_scope, global_scope, current_lexer);
- if (getter == nullptr || getter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("Reference to non-existent or invalid getter: " + (yyvsp[-6].u.identifier)->get_fully_scoped_name(), (yylsp[-6]));
-
- } else {
- CPPMakeProperty *make_property = new CPPMakeProperty((yyvsp[-8].u.identifier), CPPMakeProperty::T_normal, current_scope, (yylsp[-10]).file);
- make_property->_get_function = getter->as_function_group();
-
- CPPDeclaration *setter = (yyvsp[-4].u.identifier)->find_symbol(current_scope, global_scope, current_lexer);
- if (setter == nullptr || setter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("Reference to non-existent or invalid setter: " + (yyvsp[-4].u.identifier)->get_fully_scoped_name(), (yylsp[-4]));
- } else {
- make_property->_set_function = setter->as_function_group();
- }
-
- CPPDeclaration *deleter = (yyvsp[-2].u.identifier)->find_symbol(current_scope, global_scope, current_lexer);
- if (deleter == nullptr || deleter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("reference to non-existent or invalid delete method: " + (yyvsp[-2].u.identifier)->get_fully_scoped_name(), (yylsp[-2]));
- } else {
- make_property->_del_function = deleter->as_function_group();
- }
-
- current_scope->add_declaration(make_property, global_scope, current_lexer, (yylsp[-10]));
- }
-}
-#line 4079 "built/tmp/cppBison.yxx.c"
- break;
-
- case 30: /* declaration: KW_MAKE_SEQ_PROPERTY '(' name ',' IDENTIFIER ',' IDENTIFIER ')' ';' */
-#line 630 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPDeclaration *length_getter = (yyvsp[-4].u.identifier)->find_symbol(current_scope, global_scope, current_lexer);
- if (length_getter == nullptr || length_getter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("reference to non-existent or invalid length method: " + (yyvsp[-4].u.identifier)->get_fully_scoped_name(), (yylsp[-4]));
- length_getter = nullptr;
- }
-
- CPPDeclaration *getter = (yyvsp[-2].u.identifier)->find_symbol(current_scope, global_scope, current_lexer);
- if (getter == nullptr || getter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("Reference to non-existent or invalid getter: " + (yyvsp[-2].u.identifier)->get_fully_scoped_name(), (yylsp[-2]));
- getter = nullptr;
- }
-
- if (getter != nullptr && length_getter != nullptr) {
- CPPMakeProperty *make_property = new CPPMakeProperty((yyvsp[-6].u.identifier), CPPMakeProperty::T_sequence, current_scope, (yylsp[-8]).file);
- make_property->_get_function = getter->as_function_group();
- make_property->_length_function = length_getter->as_function_group();
- current_scope->add_declaration(make_property, global_scope, current_lexer, (yylsp[-8]));
- }
-}
-#line 4104 "built/tmp/cppBison.yxx.c"
- break;
-
- case 31: /* declaration: KW_MAKE_SEQ_PROPERTY '(' name ',' IDENTIFIER ',' IDENTIFIER ',' IDENTIFIER ')' ';' */
-#line 651 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPDeclaration *length_getter = (yyvsp[-6].u.identifier)->find_symbol(current_scope, global_scope, current_lexer);
- if (length_getter == nullptr || length_getter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("reference to non-existent or invalid length method: " + (yyvsp[-6].u.identifier)->get_fully_scoped_name(), (yylsp[-6]));
- length_getter = nullptr;
- }
-
- CPPDeclaration *getter = (yyvsp[-4].u.identifier)->find_symbol(current_scope, global_scope, current_lexer);
- if (getter == nullptr || getter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("Reference to non-existent or invalid getter: " + (yyvsp[-4].u.identifier)->get_fully_scoped_name(), (yylsp[-4]));
- getter = nullptr;
- }
-
- if (getter != nullptr && length_getter != nullptr) {
- CPPMakeProperty *make_property = new CPPMakeProperty((yyvsp[-8].u.identifier), CPPMakeProperty::T_sequence, current_scope, (yylsp[-10]).file);
- make_property->_get_function = getter->as_function_group();
- make_property->_length_function = length_getter->as_function_group();
-
- CPPDeclaration *setter = (yyvsp[-2].u.identifier)->find_symbol(current_scope, global_scope, current_lexer);
- if (setter == nullptr || setter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("Reference to non-existent or invalid setter: " + (yyvsp[-2].u.identifier)->get_fully_scoped_name(), (yylsp[-2]));
- } else {
- make_property->_set_function = setter->as_function_group();
- }
-
- current_scope->add_declaration(make_property, global_scope, current_lexer, (yylsp[-10]));
- }
-}
-#line 4137 "built/tmp/cppBison.yxx.c"
- break;
-
- case 32: /* declaration: KW_MAKE_SEQ_PROPERTY '(' name ',' IDENTIFIER ',' IDENTIFIER ',' IDENTIFIER ',' IDENTIFIER ')' ';' */
-#line 680 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPDeclaration *length_getter = (yyvsp[-8].u.identifier)->find_symbol(current_scope, global_scope, current_lexer);
- if (length_getter == nullptr || length_getter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("reference to non-existent or invalid length method: " + (yyvsp[-8].u.identifier)->get_fully_scoped_name(), (yylsp[-8]));
- length_getter = nullptr;
- }
-
- CPPDeclaration *getter = (yyvsp[-6].u.identifier)->find_symbol(current_scope, global_scope, current_lexer);
- if (getter == nullptr || getter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("Reference to non-existent or invalid getter: " + (yyvsp[-6].u.identifier)->get_fully_scoped_name(), (yylsp[-6]));
- getter = nullptr;
- }
-
- if (getter != nullptr && length_getter != nullptr) {
- CPPMakeProperty *make_property = new CPPMakeProperty((yyvsp[-10].u.identifier), CPPMakeProperty::T_sequence, current_scope, (yylsp[-12]).file);
- make_property->_get_function = getter->as_function_group();
- make_property->_length_function = length_getter->as_function_group();
-
- CPPDeclaration *setter = (yyvsp[-4].u.identifier)->find_symbol(current_scope, global_scope, current_lexer);
- if (setter == nullptr || setter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("Reference to non-existent or invalid setter: " + (yyvsp[-4].u.identifier)->get_fully_scoped_name(), (yylsp[-4]));
- } else {
- make_property->_set_function = setter->as_function_group();
- }
-
- CPPDeclaration *deleter = (yyvsp[-2].u.identifier)->find_symbol(current_scope, global_scope, current_lexer);
- if (deleter == nullptr || deleter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("reference to non-existent or invalid delete method: " + (yyvsp[-2].u.identifier)->get_fully_scoped_name(), (yylsp[-2]));
- } else {
- make_property->_del_function = deleter->as_function_group();
- }
-
- current_scope->add_declaration(make_property, global_scope, current_lexer, (yylsp[-12]));
- }
-}
-#line 4177 "built/tmp/cppBison.yxx.c"
- break;
-
- case 33: /* declaration: KW_MAKE_SEQ_PROPERTY '(' name ',' IDENTIFIER ',' IDENTIFIER ',' IDENTIFIER ',' IDENTIFIER ',' IDENTIFIER ')' ';' */
-#line 716 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPDeclaration *length_getter = (yyvsp[-10].u.identifier)->find_symbol(current_scope, global_scope, current_lexer);
- if (length_getter == nullptr || length_getter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("reference to non-existent or invalid length method: " + (yyvsp[-10].u.identifier)->get_fully_scoped_name(), (yylsp[-10]));
- length_getter = nullptr;
- }
-
- CPPDeclaration *getter = (yyvsp[-8].u.identifier)->find_symbol(current_scope, global_scope, current_lexer);
- if (getter == nullptr || getter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("Reference to non-existent or invalid getter: " + (yyvsp[-8].u.identifier)->get_fully_scoped_name(), (yylsp[-8]));
- getter = nullptr;
- }
-
- if (getter != nullptr && length_getter != nullptr) {
- CPPMakeProperty *make_property = new CPPMakeProperty((yyvsp[-12].u.identifier), CPPMakeProperty::T_sequence, current_scope, (yylsp[-14]).file);
- make_property->_get_function = getter->as_function_group();
- make_property->_length_function = length_getter->as_function_group();
-
- CPPDeclaration *setter = (yyvsp[-6].u.identifier)->find_symbol(current_scope, global_scope, current_lexer);
- if (setter == nullptr || setter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("Reference to non-existent or invalid setter: " + (yyvsp[-6].u.identifier)->get_fully_scoped_name(), (yylsp[-6]));
- } else {
- make_property->_set_function = setter->as_function_group();
- }
-
- CPPDeclaration *deleter = (yyvsp[-4].u.identifier)->find_symbol(current_scope, global_scope, current_lexer);
- if (deleter == nullptr || deleter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("reference to non-existent or invalid delete method: " + (yyvsp[-4].u.identifier)->get_fully_scoped_name(), (yylsp[-4]));
- } else {
- make_property->_del_function = deleter->as_function_group();
- }
-
- CPPDeclaration *inserter = (yyvsp[-2].u.identifier)->find_symbol(current_scope, global_scope, current_lexer);
- if (inserter == nullptr || inserter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("reference to non-existent or invalid append method: " + (yyvsp[-2].u.identifier)->get_fully_scoped_name(), (yylsp[-2]));
- } else {
- make_property->_insert_function = inserter->as_function_group();
- }
-
- current_scope->add_declaration(make_property, global_scope, current_lexer, (yylsp[-14]));
- }
-}
-#line 4224 "built/tmp/cppBison.yxx.c"
- break;
-
- case 34: /* declaration: KW_MAKE_MAP_PROPERTY '(' name ',' IDENTIFIER ')' ';' */
-#line 759 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPDeclaration *getter = (yyvsp[-2].u.identifier)->find_symbol(current_scope, global_scope, current_lexer);
- if (getter == nullptr || getter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("reference to non-existent or invalid item getter method: " + (yyvsp[-2].u.identifier)->get_fully_scoped_name(), (yylsp[-2]));
-
- } else {
- CPPMakeProperty *make_property = new CPPMakeProperty((yyvsp[-4].u.identifier), CPPMakeProperty::T_mapping, current_scope, (yylsp[-6]).file);
- make_property->_get_function = getter->as_function_group();
- current_scope->add_declaration(make_property, global_scope, current_lexer, (yylsp[-6]));
- }
-}
-#line 4240 "built/tmp/cppBison.yxx.c"
- break;
-
- case 35: /* declaration: KW_MAKE_MAP_PROPERTY '(' name ',' IDENTIFIER ',' IDENTIFIER ')' ';' */
-#line 771 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPDeclaration *getter = (yyvsp[-2].u.identifier)->find_symbol(current_scope, global_scope, current_lexer);
- if (getter == nullptr || getter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("Reference to non-existent or invalid getter: " + (yyvsp[-2].u.identifier)->get_fully_scoped_name(), (yylsp[-2]));
-
- } else {
- CPPMakeProperty *make_property;
- make_property = new CPPMakeProperty((yyvsp[-6].u.identifier), CPPMakeProperty::T_mapping, current_scope, (yylsp[-8]).file);
- make_property->_get_function = getter->as_function_group();
-
- CPPDeclaration *hasser = (yyvsp[-4].u.identifier)->find_symbol(current_scope, global_scope, current_lexer);
- if (hasser == nullptr || hasser->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("reference to non-existent or invalid has/find method: " + (yyvsp[-4].u.identifier)->get_fully_scoped_name(), (yylsp[-4]));
- } else {
- make_property->_has_function = hasser->as_function_group();
- }
-
- current_scope->add_declaration(make_property, global_scope, current_lexer, (yylsp[-8]));
- }
-}
-#line 4265 "built/tmp/cppBison.yxx.c"
- break;
-
- case 36: /* declaration: KW_MAKE_MAP_PROPERTY '(' name ',' IDENTIFIER ',' IDENTIFIER ',' IDENTIFIER maybe_comma_identifier ')' ';' */
-#line 792 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPDeclaration *getter = (yyvsp[-5].u.identifier)->find_symbol(current_scope, global_scope, current_lexer);
- if (getter == nullptr || getter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("Reference to non-existent or invalid getter: " + (yyvsp[-5].u.identifier)->get_fully_scoped_name(), (yylsp[-5]));
-
- } else {
- CPPMakeProperty *make_property = new CPPMakeProperty((yyvsp[-9].u.identifier), CPPMakeProperty::T_mapping, current_scope, (yylsp[-11]).file);
- make_property->_get_function = getter->as_function_group();
-
- CPPDeclaration *hasser = (yyvsp[-7].u.identifier)->find_symbol(current_scope, global_scope, current_lexer);
- if (hasser == nullptr || hasser->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("reference to non-existent or invalid has/find method: " + (yyvsp[-7].u.identifier)->get_fully_scoped_name(), (yylsp[-7]));
- } else {
- make_property->_has_function = hasser->as_function_group();
- }
-
- CPPDeclaration *setter = (yyvsp[-3].u.identifier)->find_symbol(current_scope, global_scope, current_lexer);
- if (setter == nullptr || setter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("Reference to non-existent or invalid setter: " + (yyvsp[-3].u.identifier)->get_fully_scoped_name(), (yylsp[-3]));
- } else {
- make_property->_set_function = setter->as_function_group();
- }
-
- if ((yyvsp[-2].u.identifier) != nullptr) {
- CPPDeclaration *deleter = (yyvsp[-2].u.identifier)->find_symbol(current_scope, global_scope, current_lexer);
- if (deleter == nullptr || deleter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("reference to non-existent or invalid delete method: " + (yyvsp[-2].u.identifier)->get_fully_scoped_name(), (yylsp[-2]));
- } else {
- make_property->_del_function = deleter->as_function_group();
- }
- }
-
- current_scope->add_declaration(make_property, global_scope, current_lexer, (yylsp[-11]));
- }
-}
-#line 4305 "built/tmp/cppBison.yxx.c"
- break;
-
- case 37: /* declaration: KW_MAKE_MAP_KEYS_SEQ '(' name ',' IDENTIFIER ',' IDENTIFIER ')' ';' */
-#line 828 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPDeclaration *length_getter = (yyvsp[-4].u.identifier)->find_symbol(current_scope, global_scope, current_lexer);
- if (length_getter == nullptr || length_getter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("reference to non-existent or invalid length method: " + (yyvsp[-4].u.identifier)->get_fully_scoped_name(), (yylsp[-4]));
- length_getter = nullptr;
- }
-
- CPPDeclaration *getter = (yyvsp[-2].u.identifier)->find_symbol(current_scope, global_scope, current_lexer);
- if (getter == nullptr || getter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("reference to non-existent or invalid getter: " + (yyvsp[-2].u.identifier)->get_fully_scoped_name(), (yylsp[-2]));
- getter = nullptr;
- }
-
- if (getter != nullptr && length_getter != nullptr) {
- CPPMakeProperty *make_property = nullptr;
- for (size_t i = 0; i < current_scope->_declarations.size(); ++i) {
- make_property = current_scope->_declarations[i]->as_make_property();
- if (make_property != nullptr) {
- if (make_property->get_fully_scoped_name() == (yyvsp[-6].u.identifier)->get_fully_scoped_name()) {
- break;
- } else {
- make_property = nullptr;
- }
- }
- }
- if (make_property != nullptr) {
- make_property->_get_key_function = getter->as_function_group();
- make_property->_length_function = length_getter->as_function_group();
- } else {
- yyerror("reference to non-existent MAKE_MAP_PROPERTY: " + (yyvsp[-6].u.identifier)->get_fully_scoped_name(), (yylsp[-6]));
- }
- }
-}
-#line 4343 "built/tmp/cppBison.yxx.c"
- break;
-
- case 38: /* declaration: KW_MAKE_PROPERTY2 '(' name ',' IDENTIFIER ',' IDENTIFIER ')' ';' */
-#line 862 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPDeclaration *getter = (yyvsp[-2].u.identifier)->find_symbol(current_scope, global_scope, current_lexer);
- if (getter == nullptr || getter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("Reference to non-existent or invalid getter: " + (yyvsp[-2].u.identifier)->get_fully_scoped_name(), (yylsp[-2]));
-
- } else {
- CPPMakeProperty *make_property;
- make_property = new CPPMakeProperty((yyvsp[-6].u.identifier), CPPMakeProperty::T_normal,
- current_scope, (yylsp[-8]).file);
- make_property->_get_function = getter->as_function_group();
-
- CPPDeclaration *hasser = (yyvsp[-4].u.identifier)->find_symbol(current_scope, global_scope, current_lexer);
- if (hasser == nullptr || hasser->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("reference to non-existent or invalid has/find method: " + (yyvsp[-4].u.identifier)->get_fully_scoped_name(), (yylsp[-4]));
- } else {
- make_property->_has_function = hasser->as_function_group();
- }
-
- current_scope->add_declaration(make_property, global_scope, current_lexer, (yylsp[-8]));
- }
-}
-#line 4369 "built/tmp/cppBison.yxx.c"
- break;
-
- case 39: /* declaration: KW_MAKE_PROPERTY2 '(' name ',' IDENTIFIER ',' IDENTIFIER ',' IDENTIFIER ',' IDENTIFIER ')' ';' */
-#line 884 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPDeclaration *getter = (yyvsp[-6].u.identifier)->find_symbol(current_scope, global_scope, current_lexer);
- if (getter == nullptr || getter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("Reference to non-existent or invalid getter: " + (yyvsp[-6].u.identifier)->get_fully_scoped_name(), (yylsp[-6]));
-
- } else {
- CPPMakeProperty *make_property;
- make_property = new CPPMakeProperty((yyvsp[-10].u.identifier), CPPMakeProperty::T_normal,
- current_scope, (yylsp[-12]).file);
- make_property->_get_function = getter->as_function_group();
-
- CPPDeclaration *hasser = (yyvsp[-8].u.identifier)->find_symbol(current_scope, global_scope, current_lexer);
- if (hasser == nullptr || hasser->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("reference to non-existent or invalid has/find method: " + (yyvsp[-8].u.identifier)->get_fully_scoped_name(), (yylsp[-8]));
- } else {
- make_property->_has_function = hasser->as_function_group();
- }
-
- CPPDeclaration *setter = (yyvsp[-4].u.identifier)->find_symbol(current_scope, global_scope, current_lexer);
- if (setter == nullptr || setter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("reference to non-existent or invalid setter: " + (yyvsp[-4].u.identifier)->get_fully_scoped_name(), (yylsp[-4]));
- } else {
- make_property->_set_function = setter->as_function_group();
- }
-
- CPPDeclaration *clearer = (yyvsp[-2].u.identifier)->find_symbol(current_scope, global_scope, current_lexer);
- if (clearer == nullptr || clearer->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("reference to non-existent or invalid clear method: " + (yyvsp[-2].u.identifier)->get_fully_scoped_name(), (yylsp[-2]));
- } else {
- make_property->_clear_function = clearer->as_function_group();
- }
-
- current_scope->add_declaration(make_property, global_scope, current_lexer, (yylsp[-12]));
- }
-}
-#line 4409 "built/tmp/cppBison.yxx.c"
- break;
-
- case 40: /* declaration: KW_MAKE_SEQ '(' name ',' IDENTIFIER ',' IDENTIFIER ')' ';' */
-#line 920 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPDeclaration *length_getter = (yyvsp[-4].u.identifier)->find_symbol(current_scope, global_scope, current_lexer);
- if (length_getter == nullptr || length_getter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("reference to non-existent or invalid length method: " + (yyvsp[-4].u.identifier)->get_fully_scoped_name(), (yylsp[-4]));
- length_getter = nullptr;
- }
-
- CPPDeclaration *element_getter = (yyvsp[-2].u.identifier)->find_symbol(current_scope, global_scope, current_lexer);
- if (element_getter == nullptr || element_getter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("reference to non-existent or invalid element method: " + (yyvsp[-2].u.identifier)->get_fully_scoped_name(), (yylsp[-4]));
- element_getter = nullptr;
- }
-
- if (length_getter != nullptr && element_getter != nullptr) {
- CPPMakeSeq *make_seq = new CPPMakeSeq((yyvsp[-6].u.identifier),
- length_getter->as_function_group(),
- element_getter->as_function_group(),
- current_scope, (yylsp[-8]).file);
- current_scope->add_declaration(make_seq, global_scope, current_lexer, (yylsp[-8]));
- }
-}
-#line 4435 "built/tmp/cppBison.yxx.c"
- break;
-
- case 41: /* declaration: KW_STATIC_ASSERT '(' const_expr ',' string_literal ')' ';' */
-#line 942 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPExpression::Result result = (yyvsp[-4].u.expr)->evaluate();
- if (result._type == CPPExpression::RT_error) {
- yywarning("static_assert requires a constant expression", (yylsp[-4]));
- } else if (!result.as_boolean()) {
- stringstream str;
- str << *(yyvsp[-2].u.expr);
- yywarning("static_assert failed: " + str.str(), (yylsp[-4]));
- }
-}
-#line 4450 "built/tmp/cppBison.yxx.c"
- break;
-
- case 42: /* declaration: KW_STATIC_ASSERT '(' const_expr ')' ';' */
-#line 953 "dtool/src/cppparser/cppBison.yxx"
-{
- // This alternative version of static_assert was introduced in C++17.
- CPPExpression::Result result = (yyvsp[-2].u.expr)->evaluate();
- if (result._type == CPPExpression::RT_error) {
- yywarning("static_assert requires a constant expression", (yylsp[-2]));
- } else if (!result.as_boolean()) {
- yywarning("static_assert failed", (yylsp[-2]));
- }
-}
-#line 4464 "built/tmp/cppBison.yxx.c"
- break;
-
- case 43: /* $@3: %empty */
-#line 966 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPScope *new_scope = new CPPScope(current_scope, CPPNameComponent("temp"),
- V_public);
- push_scope(new_scope);
-}
-#line 4474 "built/tmp/cppBison.yxx.c"
- break;
-
- case 44: /* friend_declaration: KW_FRIEND $@3 declaration */
-#line 972 "dtool/src/cppparser/cppBison.yxx"
-{
- delete current_scope;
- pop_scope();
-}
-#line 4483 "built/tmp/cppBison.yxx.c"
- break;
-
- case 45: /* storage_class: empty */
-#line 981 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.integer) = 0;
-}
-#line 4491 "built/tmp/cppBison.yxx.c"
- break;
-
- case 46: /* storage_class: KW_CONST storage_class */
-#line 985 "dtool/src/cppparser/cppBison.yxx"
-{
- // This isn't really a storage class, but it helps with parsing.
- (yyval.u.integer) = (yyvsp[0].u.integer) | (int)CPPInstance::SC_const;
-}
-#line 4500 "built/tmp/cppBison.yxx.c"
- break;
-
- case 47: /* storage_class: KW_EXTERN storage_class */
-#line 990 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.integer) = (yyvsp[0].u.integer) | (int)CPPInstance::SC_extern;
-}
-#line 4508 "built/tmp/cppBison.yxx.c"
- break;
-
- case 48: /* storage_class: KW_EXTERN SIMPLE_STRING storage_class */
-#line 994 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.integer) = (yyvsp[0].u.integer) | (int)CPPInstance::SC_extern;
- if ((yyvsp[-1].str) == "C") {
- (yyval.u.integer) |= (int)CPPInstance::SC_c_binding;
- } else if ((yyvsp[-1].str) == "C++") {
- (yyval.u.integer) &= ~(int)CPPInstance::SC_c_binding;
- } else {
- yywarning("Ignoring unknown linkage type \"" + (yyvsp[-1].str) + "\"", (yylsp[-1]));
- }
-}
-#line 4523 "built/tmp/cppBison.yxx.c"
- break;
-
- case 49: /* storage_class: KW_STATIC storage_class */
-#line 1005 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.integer) = (yyvsp[0].u.integer) | (int)CPPInstance::SC_static;
-}
-#line 4531 "built/tmp/cppBison.yxx.c"
- break;
-
- case 50: /* storage_class: KW_INLINE storage_class */
-#line 1009 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.integer) = (yyvsp[0].u.integer) | (int)CPPInstance::SC_inline;
-}
-#line 4539 "built/tmp/cppBison.yxx.c"
- break;
-
- case 51: /* storage_class: KW_VIRTUAL storage_class */
-#line 1013 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.integer) = (yyvsp[0].u.integer) | (int)CPPInstance::SC_virtual;
-}
-#line 4547 "built/tmp/cppBison.yxx.c"
- break;
-
- case 52: /* storage_class: KW_EXPLICIT storage_class */
-#line 1017 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.integer) = (yyvsp[0].u.integer) | (int)CPPInstance::SC_explicit;
-}
-#line 4555 "built/tmp/cppBison.yxx.c"
- break;
-
- case 53: /* storage_class: KW_EXPLICIT_LPAREN const_expr ')' storage_class */
-#line 1021 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPExpression::Result result = (yyvsp[-2].u.expr)->evaluate();
- if (result._type == CPPExpression::RT_error) {
- yywarning("explicit() requires a constant expression", (yylsp[-2]));
- } else if (result.as_boolean()) {
- (yyval.u.integer) = (yyvsp[0].u.integer) | (int)CPPInstance::SC_explicit;
- }
-}
-#line 4568 "built/tmp/cppBison.yxx.c"
- break;
-
- case 54: /* storage_class: KW_REGISTER storage_class */
-#line 1030 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.integer) = (yyvsp[0].u.integer) | (int)CPPInstance::SC_register;
-}
-#line 4576 "built/tmp/cppBison.yxx.c"
- break;
-
- case 55: /* storage_class: KW_VOLATILE storage_class */
-#line 1034 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.integer) = (yyvsp[0].u.integer) | (int)CPPInstance::SC_volatile;
-}
-#line 4584 "built/tmp/cppBison.yxx.c"
- break;
-
- case 56: /* storage_class: KW_MUTABLE storage_class */
-#line 1038 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.integer) = (yyvsp[0].u.integer) | (int)CPPInstance::SC_mutable;
-}
-#line 4592 "built/tmp/cppBison.yxx.c"
- break;
-
- case 57: /* storage_class: KW_CONSTEVAL storage_class */
-#line 1042 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.integer) = (yyvsp[0].u.integer) | (int)CPPInstance::SC_consteval;
-}
-#line 4600 "built/tmp/cppBison.yxx.c"
- break;
-
- case 58: /* storage_class: KW_CONSTEXPR storage_class */
-#line 1046 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.integer) = (yyvsp[0].u.integer) | (int)CPPInstance::SC_constexpr;
-}
-#line 4608 "built/tmp/cppBison.yxx.c"
- break;
-
- case 59: /* storage_class: KW_CONSTINIT storage_class */
-#line 1050 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.integer) = (yyvsp[0].u.integer) | (int)CPPInstance::SC_constinit;
-}
-#line 4616 "built/tmp/cppBison.yxx.c"
- break;
-
- case 60: /* storage_class: KW_BLOCKING storage_class */
-#line 1054 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.integer) = (yyvsp[0].u.integer) | (int)CPPInstance::SC_blocking;
-}
-#line 4624 "built/tmp/cppBison.yxx.c"
- break;
-
- case 61: /* storage_class: KW_EXTENSION storage_class */
-#line 1058 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.integer) = (yyvsp[0].u.integer) | (int)CPPInstance::SC_extension;
-}
-#line 4632 "built/tmp/cppBison.yxx.c"
- break;
-
- case 62: /* storage_class: KW_THREAD_LOCAL storage_class */
-#line 1062 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.integer) = (yyvsp[0].u.integer) | (int)CPPInstance::SC_thread_local;
-}
-#line 4640 "built/tmp/cppBison.yxx.c"
- break;
-
- case 63: /* optional_attributes: empty */
-#line 1069 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.attr_list) = CPPAttributeList();
-}
-#line 4648 "built/tmp/cppBison.yxx.c"
- break;
-
- case 64: /* optional_attributes: ATTR_LEFT attribute_specifiers ATTR_RIGHT optional_attributes */
-#line 1073 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.attr_list) = (yyvsp[-2].attr_list);
- (yyval.attr_list).add_attributes_from((yyvsp[0].attr_list));
-}
-#line 4657 "built/tmp/cppBison.yxx.c"
- break;
-
- case 65: /* optional_attributes: ATTR_LEFT KW_USING name ':' attribute_specifiers ATTR_RIGHT optional_attributes */
-#line 1078 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.attr_list) = (yyvsp[-2].attr_list);
- for (CPPAttributeList::Attribute &attr : (yyval.attr_list)._attributes) {
- attr._ident->prepend((yyvsp[-4].u.identifier));
- }
- (yyval.attr_list).add_attributes_from((yyvsp[0].attr_list));
-}
-#line 4669 "built/tmp/cppBison.yxx.c"
- break;
-
- case 66: /* optional_attributes: KW_ALIGNAS '(' const_expr ')' optional_attributes */
-#line 1086 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.attr_list) = (yyvsp[0].attr_list);
- (yyval.attr_list).add_alignas((yyvsp[-2].u.expr)->as_expression());
-}
-#line 4678 "built/tmp/cppBison.yxx.c"
- break;
-
- case 67: /* optional_attributes: KW_ALIGNAS '(' type_decl ')' optional_attributes */
-#line 1091 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.attr_list) = (yyvsp[0].attr_list);
- (yyval.attr_list).add_alignas((yyvsp[-2].u.decl)->as_type());
-}
-#line 4687 "built/tmp/cppBison.yxx.c"
- break;
-
- case 68: /* attribute_specifiers: attribute_specifier */
-#line 1099 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.attr_list) = (yyvsp[0].attr_list);
-}
-#line 4695 "built/tmp/cppBison.yxx.c"
- break;
-
- case 69: /* attribute_specifiers: attribute_specifier ',' attribute_specifiers */
-#line 1103 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.attr_list) = (yyvsp[-2].attr_list);
- (yyval.attr_list).add_attributes_from((yyvsp[0].attr_list));
-}
-#line 4704 "built/tmp/cppBison.yxx.c"
- break;
-
- case 70: /* attribute_specifier: name */
-#line 1111 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.attr_list) = CPPAttributeList();
- (yyval.attr_list).add_attribute((yyvsp[0].u.identifier));
-}
-#line 4713 "built/tmp/cppBison.yxx.c"
- break;
-
- case 71: /* attribute_specifier: name '(' formal_parameter_list ')' */
-#line 1116 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.attr_list) = CPPAttributeList();
- (yyval.attr_list).add_attribute((yyvsp[-3].u.identifier));
-}
-#line 4722 "built/tmp/cppBison.yxx.c"
- break;
-
- case 72: /* $@4: %empty */
-#line 1124 "dtool/src/cppparser/cppBison.yxx"
-{
- // We don't need to push/pop type, because we can't nest
- // type_like_declaration.
- if ((yyvsp[0].u.decl)->as_type_declaration()) {
- current_type = (yyvsp[0].u.decl)->as_type_declaration()->_type;
- } else {
- current_type = (yyvsp[0].u.decl)->as_type();
- }
- push_storage_class((yyvsp[-1].u.integer));
-}
-#line 4737 "built/tmp/cppBison.yxx.c"
- break;
-
- case 73: /* type_like_declaration: storage_class var_type_decl $@4 multiple_instance_identifiers */
-#line 1135 "dtool/src/cppparser/cppBison.yxx"
-{
- pop_storage_class();
-}
-#line 4745 "built/tmp/cppBison.yxx.c"
- break;
-
- case 74: /* type_like_declaration: storage_class type_decl ';' */
-#line 1140 "dtool/src/cppparser/cppBison.yxx"
-{
- // We don't really care about the storage class here. In fact, it's
- // not actually legal to define a class or struct using a particular
- // storage class, but we require it just to help yacc out in its
- // parsing.
-
- current_scope->add_declaration((yyvsp[-1].u.decl), global_scope, current_lexer, (yylsp[-1]));
-}
-#line 4758 "built/tmp/cppBison.yxx.c"
- break;
-
- case 75: /* $@5: %empty */
-#line 1149 "dtool/src/cppparser/cppBison.yxx"
-{
- if ((yyvsp[0].u.instance) != nullptr) {
- // Push the scope so that the initializers can make use of things defined
- // in the class body.
- push_scope((yyvsp[0].u.instance)->get_scope(current_scope, global_scope));
- (yyvsp[0].u.instance)->_storage_class |= (current_storage_class | (yyvsp[-1].u.integer));
- }
-}
-#line 4771 "built/tmp/cppBison.yxx.c"
- break;
-
- case 76: /* type_like_declaration: storage_class constructor_prototype $@5 maybe_initialize_or_constructor_body */
-#line 1158 "dtool/src/cppparser/cppBison.yxx"
-{
- if ((yyvsp[-2].u.instance) != nullptr) {
- pop_scope();
- current_scope->add_declaration((yyvsp[-2].u.instance), global_scope, current_lexer, (yylsp[-2]));
- (yyvsp[-2].u.instance)->set_initializer((yyvsp[0].u.expr));
- }
-}
-#line 4783 "built/tmp/cppBison.yxx.c"
- break;
-
- case 77: /* type_like_declaration: storage_class function_prototype maybe_initialize_or_function_body */
-#line 1166 "dtool/src/cppparser/cppBison.yxx"
-{
- if ((yyvsp[-1].u.instance) != nullptr) {
- (yyvsp[-1].u.instance)->_storage_class |= (current_storage_class | (yyvsp[-2].u.integer));
- current_scope->add_declaration((yyvsp[-1].u.instance), global_scope, current_lexer, (yylsp[-1]));
- (yyvsp[-1].u.instance)->set_initializer((yyvsp[0].u.expr));
- }
-}
-#line 4795 "built/tmp/cppBison.yxx.c"
- break;
-
- case 79: /* multiple_instance_identifiers: instance_identifier_and_maybe_trailing_return_type maybe_initialize_or_function_body */
-#line 1182 "dtool/src/cppparser/cppBison.yxx"
-{
- if (current_storage_class & CPPInstance::SC_const) {
- (yyvsp[-1].u.inst_ident)->add_modifier(IIT_const);
- }
- (yyvsp[-1].u.inst_ident)->add_attributes(current_attributes);
- CPPInstance *inst = new CPPInstance(current_type, (yyvsp[-1].u.inst_ident),
- current_storage_class,
- (yylsp[-1]).file);
- inst->set_initializer((yyvsp[0].u.expr));
- current_scope->add_declaration(inst, global_scope, current_lexer, (yylsp[-1]));
-}
-#line 4811 "built/tmp/cppBison.yxx.c"
- break;
-
- case 80: /* multiple_instance_identifiers: instance_identifier_and_maybe_trailing_return_type maybe_initialize ',' multiple_instance_identifiers */
-#line 1194 "dtool/src/cppparser/cppBison.yxx"
-{
- if (current_storage_class & CPPInstance::SC_const) {
- (yyvsp[-3].u.inst_ident)->add_modifier(IIT_const);
- }
- (yyvsp[-3].u.inst_ident)->add_attributes(current_attributes);
- CPPInstance *inst = new CPPInstance(current_type, (yyvsp[-3].u.inst_ident),
- current_storage_class,
- (yylsp[-3]).file);
- inst->set_initializer((yyvsp[-2].u.expr));
- current_scope->add_declaration(inst, global_scope, current_lexer, (yylsp[-3]));
-}
-#line 4827 "built/tmp/cppBison.yxx.c"
- break;
-
- case 81: /* $@6: %empty */
-#line 1210 "dtool/src/cppparser/cppBison.yxx"
-{
- // We don't need to push/pop type, because we can't nest
- // multiple_var_declarations.
- if ((yyvsp[0].u.decl)->as_type_declaration()) {
- current_type = (yyvsp[0].u.decl)->as_type_declaration()->_type;
- } else {
- current_type = (yyvsp[0].u.decl)->as_type();
- }
- push_storage_class((yyvsp[-1].u.integer));
-}
-#line 4842 "built/tmp/cppBison.yxx.c"
- break;
-
- case 82: /* typedef_declaration: storage_class var_type_decl $@6 typedef_instance_identifiers */
-#line 1221 "dtool/src/cppparser/cppBison.yxx"
-{
- pop_storage_class();
-}
-#line 4850 "built/tmp/cppBison.yxx.c"
- break;
-
- case 83: /* typedef_declaration: storage_class function_prototype maybe_initialize_or_function_body */
-#line 1225 "dtool/src/cppparser/cppBison.yxx"
-{
- if ((yyvsp[-1].u.instance) != nullptr) {
- CPPInstance *inst = (yyvsp[-1].u.instance)->as_instance();
- if (inst != nullptr) {
- inst->_storage_class |= (current_storage_class | (yyvsp[-2].u.integer));
- current_scope->add_declaration(inst, global_scope, current_lexer, (yylsp[-1]));
- CPPTypedefType *typedef_type = new CPPTypedefType(inst->_type, inst->_ident, current_scope, inst->_attributes);
- current_scope->add_declaration(CPPType::new_type(typedef_type), global_scope, current_lexer, (yylsp[-1]));
- }
- }
-}
-#line 4866 "built/tmp/cppBison.yxx.c"
- break;
-
- case 84: /* typedef_instance_identifiers: instance_identifier_and_maybe_trailing_return_type maybe_initialize_or_function_body */
-#line 1240 "dtool/src/cppparser/cppBison.yxx"
-{
- if (current_storage_class & CPPInstance::SC_const) {
- (yyvsp[-1].u.inst_ident)->add_modifier(IIT_const);
- }
- (yyvsp[-1].u.inst_ident)->add_attributes(current_attributes);
- CPPType *target_type = current_type;
- CPPTypedefType *typedef_type = new CPPTypedefType(target_type, (yyvsp[-1].u.inst_ident), current_scope, (yylsp[-1]).file);
- current_scope->add_declaration(CPPType::new_type(typedef_type), global_scope, current_lexer, (yylsp[-1]));
-}
-#line 4880 "built/tmp/cppBison.yxx.c"
- break;
-
- case 85: /* typedef_instance_identifiers: instance_identifier_and_maybe_trailing_return_type maybe_initialize ',' typedef_instance_identifiers */
-#line 1250 "dtool/src/cppparser/cppBison.yxx"
-{
- if (current_storage_class & CPPInstance::SC_const) {
- (yyvsp[-3].u.inst_ident)->add_modifier(IIT_const);
- }
- (yyvsp[-3].u.inst_ident)->add_attributes(current_attributes);
- CPPType *target_type = current_type;
- CPPTypedefType *typedef_type = new CPPTypedefType(target_type, (yyvsp[-3].u.inst_ident), current_scope, (yylsp[-3]).file);
- current_scope->add_declaration(CPPType::new_type(typedef_type), global_scope, current_lexer, (yylsp[-3]));
-}
-#line 4894 "built/tmp/cppBison.yxx.c"
- break;
-
- case 86: /* $@7: %empty */
-#line 1265 "dtool/src/cppparser/cppBison.yxx"
-{
- // Create a scope for this function.
- CPPScope *scope = new CPPScope((yyvsp[-1].u.identifier)->get_scope(current_scope, global_scope),
- (yyvsp[-1].u.identifier)->_names.back(), V_private);
-
- // It still needs to be able to pick up any template arguments, if this is
- // a definition for a method template. Add a fake "using" declaration to
- // accomplish this.
- scope->_using.insert(current_scope);
-
- push_scope(scope);
-}
-#line 4911 "built/tmp/cppBison.yxx.c"
- break;
-
- case 87: /* constructor_prototype: IDENTIFIER '(' $@7 function_parameter_list ')' function_post optional_attributes */
-#line 1278 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPScope *scope = (yyvsp[-6].u.identifier)->get_scope(current_scope, global_scope);
- CPPType *type;
- std::string simple_name = (yyvsp[-6].u.identifier)->get_simple_name();
- if (!simple_name.empty() && simple_name[0] == '~') {
- // A destructor has no return type.
- type = new CPPSimpleType(CPPSimpleType::T_void);
- }
- else if (scope != nullptr && simple_name == scope->get_simple_name()) {
- // Neither does a constructor.
- type = new CPPSimpleType(CPPSimpleType::T_void);
- }
- else {
- // This isn't a constructor, so it has an implicit return type of
- // int.
- yywarning("function has no return type, assuming int", (yylsp[-6]));
- type = new CPPSimpleType(CPPSimpleType::T_int);
- }
- pop_scope();
-
- CPPInstanceIdentifier *ii = new CPPInstanceIdentifier((yyvsp[-6].u.identifier));
- ii->add_func_modifier((yyvsp[-3].u.param_list), (yyvsp[-1].u.integer), nullptr, (yyvsp[0].attr_list));
- ii->add_attributes(current_attributes);
-
- (yyval.u.instance) = new CPPInstance(type, ii, 0, (yylsp[-6]).file);
-}
-#line 4942 "built/tmp/cppBison.yxx.c"
- break;
-
- case 88: /* $@8: %empty */
-#line 1307 "dtool/src/cppparser/cppBison.yxx"
-{
- // Create a scope for this function.
- CPPScope *scope = new CPPScope((yyvsp[-2].u.identifier)->get_scope(current_scope, global_scope),
- (yyvsp[-2].u.identifier)->_names.back(), V_private);
-
- // It still needs to be able to pick up any template arguments, if this is
- // a definition for a method template. Add a fake "using" declaration to
- // accomplish this.
- scope->_using.insert(current_scope);
-
- push_scope(scope);
-}
-#line 4959 "built/tmp/cppBison.yxx.c"
- break;
-
- case 89: /* constructor_prototype: TYPENAME_IDENTIFIER '(' IDENTIFIER ')' '(' $@8 function_parameter_list ')' function_post optional_attributes */
-#line 1320 "dtool/src/cppparser/cppBison.yxx"
-{
- pop_scope();
- CPPType *type = (yyvsp[-9].u.identifier)->find_type(current_scope, global_scope, false, current_lexer);
- if (type == nullptr) {
- yyerror(string("internal error resolving type ") + (yyvsp[-9].u.identifier)->get_fully_scoped_name(), (yylsp[-9]));
- }
- assert(type != nullptr);
-
- CPPInstanceIdentifier *ii = new CPPInstanceIdentifier((yyvsp[-7].u.identifier));
- ii->add_func_modifier((yyvsp[-3].u.param_list), (yyvsp[-1].u.integer), nullptr, (yyvsp[0].attr_list));
- ii->add_attributes(current_attributes);
-
- (yyval.u.instance) = new CPPInstance(type, ii, 0, (yylsp[-9]).file);
-}
-#line 4978 "built/tmp/cppBison.yxx.c"
- break;
-
- case 90: /* $@9: %empty */
-#line 1335 "dtool/src/cppparser/cppBison.yxx"
-{
- // Create a scope for this function.
- CPPScope *scope = new CPPScope((yyvsp[-1].u.identifier)->get_scope(current_scope, global_scope),
- (yyvsp[-1].u.identifier)->_names.back(), V_private);
-
- // It still needs to be able to pick up any template arguments, if this is
- // a definition for a method template. Add a fake "using" declaration to
- // accomplish this.
- scope->_using.insert(current_scope);
-
- push_scope(scope);
-}
-#line 4995 "built/tmp/cppBison.yxx.c"
- break;
-
- case 91: /* constructor_prototype: TYPENAME_IDENTIFIER '(' $@9 function_parameter_list ')' function_post optional_attributes */
-#line 1348 "dtool/src/cppparser/cppBison.yxx"
-{
- pop_scope();
- CPPType *type;
- if ((yyvsp[-6].u.identifier)->get_simple_name() == current_scope->get_simple_name()) {
- // This is a constructor, and has no return.
- type = new CPPSimpleType(CPPSimpleType::T_void);
- } else {
- // This isn't a constructor, so it has an implicit return type of
- // int.
- type = new CPPSimpleType(CPPSimpleType::T_int);
- }
-
- CPPInstanceIdentifier *ii = new CPPInstanceIdentifier((yyvsp[-6].u.identifier));
- ii->add_func_modifier((yyvsp[-3].u.param_list), (yyvsp[-1].u.integer), nullptr, (yyvsp[0].attr_list));
- ii->add_attributes(current_attributes);
-
- (yyval.u.instance) = new CPPInstance(type, ii, 0, (yylsp[-6]).file);
-}
-#line 5018 "built/tmp/cppBison.yxx.c"
- break;
-
- case 92: /* $@10: %empty */
-#line 1372 "dtool/src/cppparser/cppBison.yxx"
-{
- push_scope((yyvsp[-1].u.identifier)->get_scope(current_scope, global_scope));
-}
-#line 5026 "built/tmp/cppBison.yxx.c"
- break;
-
- case 93: /* function_prototype: '~' name '(' $@10 function_parameter_list ')' function_post optional_attributes */
-#line 1376 "dtool/src/cppparser/cppBison.yxx"
-{
- pop_scope();
- if ((yyvsp[-6].u.identifier)->is_scoped()) {
- yyerror("Invalid destructor name: ~" + (yyvsp[-6].u.identifier)->get_fully_scoped_name(), (yylsp[-6]));
- } else {
- CPPIdentifier *ident =
- new CPPIdentifier("~" + (yyvsp[-6].u.identifier)->get_simple_name(), (yylsp[-6]));
- delete (yyvsp[-6].u.identifier);
-
- CPPType *type;
- type = new CPPSimpleType(CPPSimpleType::T_void);
-
- CPPInstanceIdentifier *ii = new CPPInstanceIdentifier(ident);
- ii->add_func_modifier((yyvsp[-3].u.param_list), (yyvsp[-1].u.integer), nullptr, (yyvsp[0].attr_list));
- ii->add_attributes(current_attributes);
-
- (yyval.u.instance) = new CPPInstance(type, ii, 0, (yylsp[-6]).file);
- }
-}
-#line 5050 "built/tmp/cppBison.yxx.c"
- break;
-
- case 94: /* $@11: %empty */
-#line 1403 "dtool/src/cppparser/cppBison.yxx"
-{
- push_scope((yyvsp[-2].u.inst_ident)->get_scope(current_scope, global_scope));
-}
-#line 5058 "built/tmp/cppBison.yxx.c"
- break;
-
- case 95: /* function_prototype: TYPENAME_IDENTIFIER '(' '*' instance_identifier ')' '(' $@11 function_parameter_list ')' function_post optional_attributes maybe_trailing_return_type */
-#line 1407 "dtool/src/cppparser/cppBison.yxx"
-{
- pop_scope();
- CPPType *type = (yyvsp[-11].u.identifier)->find_type(current_scope, global_scope, false, current_lexer);
- if (type == nullptr) {
- yyerror(string("internal error resolving type ") + (yyvsp[-11].u.identifier)->get_fully_scoped_name(), (yylsp[-11]));
- }
- assert(type != nullptr);
-
- CPPInstanceIdentifier *ii = (yyvsp[-8].u.inst_ident);
- ii->add_modifier(IIT_pointer);
- ii->add_func_modifier((yyvsp[-4].u.param_list), (yyvsp[-2].u.integer), nullptr, (yyvsp[-1].attr_list));
- ii->add_attributes(current_attributes);
- (yyval.u.instance) = new CPPInstance(type, ii, 0, (yylsp[-11]).file);
-}
-#line 5077 "built/tmp/cppBison.yxx.c"
- break;
-
- case 96: /* $@12: %empty */
-#line 1422 "dtool/src/cppparser/cppBison.yxx"
-{
- push_scope((yyvsp[-2].u.inst_ident)->get_scope(current_scope, global_scope));
-}
-#line 5085 "built/tmp/cppBison.yxx.c"
- break;
-
- case 97: /* function_prototype: TYPENAME_IDENTIFIER '(' SCOPING '*' instance_identifier ')' '(' $@12 function_parameter_list ')' function_post optional_attributes maybe_trailing_return_type */
-#line 1426 "dtool/src/cppparser/cppBison.yxx"
-{
- pop_scope();
- CPPType *type = (yyvsp[-12].u.identifier)->find_type(current_scope, global_scope, false, current_lexer);
- if (type == nullptr) {
- yyerror(string("internal error resolving type ") + (yyvsp[-12].u.identifier)->get_fully_scoped_name(), (yylsp[-12]));
- }
- assert(type != nullptr);
-
- CPPInstanceIdentifier *ii = (yyvsp[-8].u.inst_ident);
- ii->add_scoped_pointer_modifier((yyvsp[-10].u.identifier));
- ii->add_func_modifier((yyvsp[-4].u.param_list), (yyvsp[-2].u.integer), nullptr, (yyvsp[-1].attr_list));
- ii->add_attributes(current_attributes);
- (yyval.u.instance) = new CPPInstance(type, ii, 0, (yylsp[-12]).file);
-}
-#line 5104 "built/tmp/cppBison.yxx.c"
- break;
-
- case 98: /* $@13: %empty */
-#line 1443 "dtool/src/cppparser/cppBison.yxx"
-{
- if ((yyvsp[-3].u.identifier) != nullptr) {
- push_scope((yyvsp[-3].u.identifier)->get_scope(current_scope, global_scope));
- }
-}
-#line 5114 "built/tmp/cppBison.yxx.c"
- break;
-
- case 99: /* function_prototype: KW_OPERATOR type not_paren_formal_parameter_identifier '(' $@13 function_parameter_list ')' function_post */
-#line 1449 "dtool/src/cppparser/cppBison.yxx"
-{
- if ((yyvsp[-7].u.identifier) != nullptr) {
- pop_scope();
- }
-
- // We use formal_parameter_identifier, because that can match a type
- // name with or without an identifier, but especially without, which
- // is what follows the keyword "operator" in a typecast function.
- // As an added bonus, the type of the formal_parameter will be the
- // typecast type, i.e. the return type of the typecast function.
-
- // We give typecast operators the name "operator typecast ",
- // where is a simple name of the type to be typecast. Use
- // the method's return type to determine the full type description.
- string name = "operator typecast " + (yyvsp[-6].u.type)->get_simple_name();
- CPPIdentifier *ident = (yyvsp[-7].u.identifier);
- if (ident == nullptr) {
- ident = new CPPIdentifier(name, (yylsp[-6]));
- } else {
- ident->add_name(name);
- }
- (yyval.u.instance) = CPPInstance::make_typecast_function
- (new CPPInstance((yyvsp[-6].u.type), (yyvsp[-5].u.inst_ident), 0, (yylsp[-5]).file), ident, (yyvsp[-2].u.param_list), (yyvsp[0].u.integer));
- (yyval.u.instance)->_attributes.add_attributes_from(current_attributes);
-}
-#line 5144 "built/tmp/cppBison.yxx.c"
- break;
-
- case 100: /* $@14: %empty */
-#line 1475 "dtool/src/cppparser/cppBison.yxx"
-{
- if ((yyvsp[-4].u.identifier) != nullptr) {
- push_scope((yyvsp[-4].u.identifier)->get_scope(current_scope, global_scope));
- }
-}
-#line 5154 "built/tmp/cppBison.yxx.c"
- break;
-
- case 101: /* function_prototype: KW_OPERATOR KW_CONST type not_paren_formal_parameter_identifier '(' $@14 function_parameter_list ')' function_post */
-#line 1481 "dtool/src/cppparser/cppBison.yxx"
-{
- if ((yyvsp[-8].u.identifier) != nullptr) {
- pop_scope();
- }
-
- CPPIdentifier *ident = (yyvsp[-8].u.identifier);
- if (ident == nullptr) {
- ident = new CPPIdentifier("operator typecast", (yylsp[-5]));
- } else {
- ident->add_name("operator typecast");
- }
- (yyvsp[-5].u.inst_ident)->add_modifier(IIT_const);
- (yyvsp[-5].u.inst_ident)->add_attributes(current_attributes);
- (yyval.u.instance) = CPPInstance::make_typecast_function
- (new CPPInstance((yyvsp[-6].u.type), (yyvsp[-5].u.inst_ident), 0, (yylsp[-5]).file), ident, (yyvsp[-2].u.param_list), (yyvsp[0].u.integer));
-}
-#line 5175 "built/tmp/cppBison.yxx.c"
- break;
-
- case 102: /* function_prototype: IDENTIFIER */
-#line 1502 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPDeclaration *decl =
- (yyvsp[0].u.identifier)->find_symbol(current_scope, global_scope, current_lexer);
- if (decl != nullptr) {
- (yyval.u.instance) = decl->as_instance();
- } else {
- (yyval.u.instance) = nullptr;
- }
-}
-#line 5189 "built/tmp/cppBison.yxx.c"
- break;
-
- case 103: /* function_post: empty */
-#line 1515 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.integer) = 0;
-}
-#line 5197 "built/tmp/cppBison.yxx.c"
- break;
-
- case 104: /* function_post: function_post KW_CONST */
-#line 1519 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.integer) = (yyvsp[-1].u.integer) | (int)CPPFunctionType::F_const_method;
-}
-#line 5205 "built/tmp/cppBison.yxx.c"
- break;
-
- case 105: /* function_post: function_post KW_VOLATILE */
-#line 1523 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.integer) = (yyvsp[-1].u.integer) | (int)CPPFunctionType::F_volatile_method;
-}
-#line 5213 "built/tmp/cppBison.yxx.c"
- break;
-
- case 106: /* function_post: function_post KW_NOEXCEPT */
-#line 1527 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.integer) = (yyvsp[-1].u.integer) | (int)CPPFunctionType::F_noexcept;
-}
-#line 5221 "built/tmp/cppBison.yxx.c"
- break;
-
- case 107: /* function_post: function_post KW_NOEXCEPT_LPAREN const_expr ')' */
-#line 1531 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPExpression::Result result = (yyvsp[-1].u.expr)->evaluate();
- if (result._type == CPPExpression::RT_error) {
- yywarning("noexcept() requires a constant expression", (yylsp[-1]));
- } else if (result.as_boolean()) {
- (yyval.u.integer) = (yyvsp[-3].u.integer) | (int)CPPFunctionType::F_noexcept;
- }
-}
-#line 5234 "built/tmp/cppBison.yxx.c"
- break;
-
- case 108: /* function_post: function_post KW_FINAL */
-#line 1540 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.integer) = (yyvsp[-1].u.integer) | (int)CPPFunctionType::F_final;
-}
-#line 5242 "built/tmp/cppBison.yxx.c"
- break;
-
- case 109: /* function_post: function_post KW_OVERRIDE */
-#line 1544 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.integer) = (yyvsp[-1].u.integer) | (int)CPPFunctionType::F_override;
-}
-#line 5250 "built/tmp/cppBison.yxx.c"
- break;
-
- case 110: /* function_post: function_post '&' */
-#line 1548 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.integer) = (yyvsp[-1].u.integer) | (int)CPPFunctionType::F_lvalue_method;
-}
-#line 5258 "built/tmp/cppBison.yxx.c"
- break;
-
- case 111: /* function_post: function_post ANDAND */
-#line 1552 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.integer) = (yyvsp[-1].u.integer) | (int)CPPFunctionType::F_rvalue_method;
-}
-#line 5266 "built/tmp/cppBison.yxx.c"
- break;
-
- case 112: /* function_post: function_post KW_MUTABLE */
-#line 1556 "dtool/src/cppparser/cppBison.yxx"
-{
- // Used for lambdas, currently ignored.
- (yyval.u.integer) = (yyvsp[-1].u.integer);
-}
-#line 5275 "built/tmp/cppBison.yxx.c"
- break;
-
- case 113: /* function_post: function_post KW_CONSTEXPR */
-#line 1561 "dtool/src/cppparser/cppBison.yxx"
-{
- // Used for lambdas in C++17, currently ignored.
- (yyval.u.integer) = (yyvsp[-1].u.integer);
-}
-#line 5284 "built/tmp/cppBison.yxx.c"
- break;
-
- case 114: /* function_post: function_post KW_THROW '(' ')' */
-#line 1566 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.integer) = (yyvsp[-3].u.integer);
-}
-#line 5292 "built/tmp/cppBison.yxx.c"
- break;
-
- case 115: /* function_post: function_post KW_THROW '(' name ')' */
-#line 1570 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.integer) = (yyvsp[-4].u.integer);
-}
-#line 5300 "built/tmp/cppBison.yxx.c"
- break;
-
- case 116: /* function_post: function_post KW_THROW '(' name ELLIPSIS ')' */
-#line 1574 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.integer) = (yyvsp[-5].u.integer);
-}
-#line 5308 "built/tmp/cppBison.yxx.c"
- break;
-
- case 117: /* function_operator: '!' */
-#line 1581 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.str) = "!";
-}
-#line 5316 "built/tmp/cppBison.yxx.c"
- break;
-
- case 118: /* function_operator: '~' */
-#line 1585 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.str) = "~";
-}
-#line 5324 "built/tmp/cppBison.yxx.c"
- break;
-
- case 119: /* function_operator: '*' */
-#line 1589 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.str) = "*";
-}
-#line 5332 "built/tmp/cppBison.yxx.c"
- break;
-
- case 120: /* function_operator: '/' */
-#line 1593 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.str) = "/";
-}
-#line 5340 "built/tmp/cppBison.yxx.c"
- break;
-
- case 121: /* function_operator: '%' */
-#line 1597 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.str) = "%";
-}
-#line 5348 "built/tmp/cppBison.yxx.c"
- break;
-
- case 122: /* function_operator: '+' */
-#line 1601 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.str) = "+";
-}
-#line 5356 "built/tmp/cppBison.yxx.c"
- break;
-
- case 123: /* function_operator: '-' */
-#line 1605 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.str) = "-";
-}
-#line 5364 "built/tmp/cppBison.yxx.c"
- break;
-
- case 124: /* function_operator: '|' */
-#line 1609 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.str) = "|";
-}
-#line 5372 "built/tmp/cppBison.yxx.c"
- break;
-
- case 125: /* function_operator: '&' */
-#line 1613 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.str) = "&";
-}
-#line 5380 "built/tmp/cppBison.yxx.c"
- break;
-
- case 126: /* function_operator: '^' */
-#line 1617 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.str) = "^";
-}
-#line 5388 "built/tmp/cppBison.yxx.c"
- break;
-
- case 127: /* function_operator: OROR */
-#line 1621 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.str) = "||";
-}
-#line 5396 "built/tmp/cppBison.yxx.c"
- break;
-
- case 128: /* function_operator: ANDAND */
-#line 1625 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.str) = "&&";
-}
-#line 5404 "built/tmp/cppBison.yxx.c"
- break;
-
- case 129: /* function_operator: EQCOMPARE */
-#line 1629 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.str) = "==";
-}
-#line 5412 "built/tmp/cppBison.yxx.c"
- break;
-
- case 130: /* function_operator: NECOMPARE */
-#line 1633 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.str) = "!=";
-}
-#line 5420 "built/tmp/cppBison.yxx.c"
- break;
-
- case 131: /* function_operator: LECOMPARE */
-#line 1637 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.str) = "<=";
-}
-#line 5428 "built/tmp/cppBison.yxx.c"
- break;
-
- case 132: /* function_operator: GECOMPARE */
-#line 1641 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.str) = ">=";
-}
-#line 5436 "built/tmp/cppBison.yxx.c"
- break;
-
- case 133: /* function_operator: '<' */
-#line 1645 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.str) = "<";
-}
-#line 5444 "built/tmp/cppBison.yxx.c"
- break;
-
- case 134: /* function_operator: '>' */
-#line 1649 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.str) = ">";
-}
-#line 5452 "built/tmp/cppBison.yxx.c"
- break;
-
- case 135: /* function_operator: SPACESHIP */
-#line 1653 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.str) = "<=>";
-}
-#line 5460 "built/tmp/cppBison.yxx.c"
- break;
-
- case 136: /* function_operator: LSHIFT */
-#line 1657 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.str) = "<<";
-}
-#line 5468 "built/tmp/cppBison.yxx.c"
- break;
-
- case 137: /* function_operator: RSHIFT */
-#line 1661 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.str) = ">>";
-}
-#line 5476 "built/tmp/cppBison.yxx.c"
- break;
-
- case 138: /* function_operator: '=' */
-#line 1665 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.str) = "=";
-}
-#line 5484 "built/tmp/cppBison.yxx.c"
- break;
-
- case 139: /* function_operator: ',' */
-#line 1669 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.str) = ",";
-}
-#line 5492 "built/tmp/cppBison.yxx.c"
- break;
-
- case 140: /* function_operator: PLUSPLUS */
-#line 1673 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.str) = "++";
-}
-#line 5500 "built/tmp/cppBison.yxx.c"
- break;
-
- case 141: /* function_operator: MINUSMINUS */
-#line 1677 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.str) = "--";
-}
-#line 5508 "built/tmp/cppBison.yxx.c"
- break;
-
- case 142: /* function_operator: TIMESEQUAL */
-#line 1681 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.str) = "*=";
-}
-#line 5516 "built/tmp/cppBison.yxx.c"
- break;
-
- case 143: /* function_operator: DIVIDEEQUAL */
-#line 1685 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.str) = "/=";
-}
-#line 5524 "built/tmp/cppBison.yxx.c"
- break;
-
- case 144: /* function_operator: MODEQUAL */
-#line 1689 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.str) = "%=";
-}
-#line 5532 "built/tmp/cppBison.yxx.c"
- break;
-
- case 145: /* function_operator: PLUSEQUAL */
-#line 1693 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.str) = "+=";
-}
-#line 5540 "built/tmp/cppBison.yxx.c"
- break;
-
- case 146: /* function_operator: MINUSEQUAL */
-#line 1697 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.str) = "-=";
-}
-#line 5548 "built/tmp/cppBison.yxx.c"
- break;
-
- case 147: /* function_operator: OREQUAL */
-#line 1701 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.str) = "|=";
-}
-#line 5556 "built/tmp/cppBison.yxx.c"
- break;
-
- case 148: /* function_operator: ANDEQUAL */
-#line 1705 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.str) = "&=";
-}
-#line 5564 "built/tmp/cppBison.yxx.c"
- break;
-
- case 149: /* function_operator: XOREQUAL */
-#line 1709 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.str) = "^=";
-}
-#line 5572 "built/tmp/cppBison.yxx.c"
- break;
-
- case 150: /* function_operator: LSHIFTEQUAL */
-#line 1713 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.str) = "<<=";
-}
-#line 5580 "built/tmp/cppBison.yxx.c"
- break;
-
- case 151: /* function_operator: RSHIFTEQUAL */
-#line 1717 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.str) = ">>=";
-}
-#line 5588 "built/tmp/cppBison.yxx.c"
- break;
-
- case 152: /* function_operator: POINTSAT */
-#line 1721 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.str) = "->";
-}
-#line 5596 "built/tmp/cppBison.yxx.c"
- break;
-
- case 153: /* function_operator: '[' ']' */
-#line 1725 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.str) = "[]";
-}
-#line 5604 "built/tmp/cppBison.yxx.c"
- break;
-
- case 154: /* function_operator: '(' ')' */
-#line 1729 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.str) = "()";
-}
-#line 5612 "built/tmp/cppBison.yxx.c"
- break;
-
- case 155: /* function_operator: KW_NEW */
-#line 1733 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.str) = "new";
-}
-#line 5620 "built/tmp/cppBison.yxx.c"
- break;
-
- case 156: /* function_operator: KW_DELETE */
-#line 1737 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.str) = "delete";
-}
-#line 5628 "built/tmp/cppBison.yxx.c"
- break;
-
- case 161: /* $@15: %empty */
-#line 1751 "dtool/src/cppparser/cppBison.yxx"
-{
- push_scope(new CPPTemplateScope(current_scope));
-}
-#line 5636 "built/tmp/cppBison.yxx.c"
- break;
-
- case 162: /* template_declaration: KW_TEMPLATE $@15 '<' template_formal_parameters '>' more_template_declaration */
-#line 1755 "dtool/src/cppparser/cppBison.yxx"
-{
- pop_scope();
-}
-#line 5644 "built/tmp/cppBison.yxx.c"
- break;
-
- case 167: /* template_nonempty_formal_parameters: template_formal_parameter */
-#line 1769 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPTemplateScope *ts = current_scope->as_template_scope();
- assert(ts != nullptr);
- ts->add_template_parameter((yyvsp[0].u.decl));
-}
-#line 5654 "built/tmp/cppBison.yxx.c"
- break;
-
- case 168: /* template_nonempty_formal_parameters: template_nonempty_formal_parameters ',' template_formal_parameter */
-#line 1775 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPTemplateScope *ts = current_scope->as_template_scope();
- assert(ts != nullptr);
- ts->add_template_parameter((yyvsp[0].u.decl));
-}
-#line 5664 "built/tmp/cppBison.yxx.c"
- break;
-
- case 171: /* template_formal_parameter: typename_keyword */
-#line 1789 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.decl) = CPPType::new_type(new CPPClassTemplateParameter(nullptr));
-}
-#line 5672 "built/tmp/cppBison.yxx.c"
- break;
-
- case 172: /* template_formal_parameter: typename_keyword name */
-#line 1793 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.decl) = CPPType::new_type(new CPPClassTemplateParameter((yyvsp[0].u.identifier)));
-}
-#line 5680 "built/tmp/cppBison.yxx.c"
- break;
-
- case 173: /* template_formal_parameter: typename_keyword name '=' full_type */
-#line 1797 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.decl) = CPPType::new_type(new CPPClassTemplateParameter((yyvsp[-2].u.identifier), (yyvsp[0].u.type)));
-}
-#line 5688 "built/tmp/cppBison.yxx.c"
- break;
-
- case 174: /* template_formal_parameter: typename_keyword ELLIPSIS */
-#line 1801 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPClassTemplateParameter *ctp = new CPPClassTemplateParameter(nullptr);
- ctp->_packed = true;
- (yyval.u.decl) = CPPType::new_type(ctp);
-}
-#line 5698 "built/tmp/cppBison.yxx.c"
- break;
-
- case 175: /* template_formal_parameter: typename_keyword ELLIPSIS name */
-#line 1807 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPClassTemplateParameter *ctp = new CPPClassTemplateParameter((yyvsp[0].u.identifier));
- ctp->_packed = true;
- (yyval.u.decl) = CPPType::new_type(ctp);
-}
-#line 5708 "built/tmp/cppBison.yxx.c"
- break;
-
- case 176: /* template_formal_parameter: template_formal_parameter_type formal_parameter_identifier template_parameter_maybe_initialize */
-#line 1813 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPInstance *inst = new CPPInstance((yyvsp[-2].u.type), (yyvsp[-1].u.inst_ident), 0, (yylsp[-1]).file);
- inst->set_initializer((yyvsp[0].u.expr));
- (yyval.u.decl) = inst;
-}
-#line 5718 "built/tmp/cppBison.yxx.c"
- break;
-
- case 177: /* template_formal_parameter: KW_CONST template_formal_parameter_type formal_parameter_identifier template_parameter_maybe_initialize */
-#line 1819 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyvsp[-1].u.inst_ident)->add_modifier(IIT_const);
- CPPInstance *inst = new CPPInstance((yyvsp[-2].u.type), (yyvsp[-1].u.inst_ident), 0, (yylsp[-1]).file);
- inst->set_initializer((yyvsp[0].u.expr));
- (yyval.u.decl) = inst;
-}
-#line 5729 "built/tmp/cppBison.yxx.c"
- break;
-
- case 178: /* template_formal_parameter: template_formal_parameter_type parameter_pack_identifier */
-#line 1826 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPInstance *inst = new CPPInstance((yyvsp[-1].u.type), (yyvsp[0].u.inst_ident), 0, (yylsp[0]).file);
- (yyval.u.decl) = inst;
-}
-#line 5738 "built/tmp/cppBison.yxx.c"
- break;
-
- case 179: /* template_formal_parameter: KW_CONST template_formal_parameter_type parameter_pack_identifier */
-#line 1831 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyvsp[0].u.inst_ident)->add_modifier(IIT_const);
- CPPInstance *inst = new CPPInstance((yyvsp[-1].u.type), (yyvsp[0].u.inst_ident), 0, (yylsp[0]).file);
- (yyval.u.decl) = inst;
-}
-#line 5748 "built/tmp/cppBison.yxx.c"
- break;
-
- case 180: /* template_formal_parameter: KW_VOLATILE template_formal_parameter_type formal_parameter_identifier template_parameter_maybe_initialize */
-#line 1837 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyvsp[-1].u.inst_ident)->add_modifier(IIT_volatile);
- CPPInstance *inst = new CPPInstance((yyvsp[-2].u.type), (yyvsp[-1].u.inst_ident), 0, (yylsp[-1]).file);
- inst->set_initializer((yyvsp[0].u.expr));
- (yyval.u.decl) = inst;
-}
-#line 5759 "built/tmp/cppBison.yxx.c"
- break;
-
- case 181: /* template_formal_parameter: KW_VOLATILE template_formal_parameter_type parameter_pack_identifier */
-#line 1844 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyvsp[0].u.inst_ident)->add_modifier(IIT_volatile);
- CPPInstance *inst = new CPPInstance((yyvsp[-1].u.type), (yyvsp[0].u.inst_ident), 0, (yylsp[0]).file);
- (yyval.u.decl) = inst;
-}
-#line 5769 "built/tmp/cppBison.yxx.c"
- break;
-
- case 182: /* template_formal_parameter_type: simple_type */
-#line 1853 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.type) = CPPType::new_type((yyvsp[0].u.simple_type));
-}
-#line 5777 "built/tmp/cppBison.yxx.c"
- break;
-
- case 183: /* template_formal_parameter_type: IDENTIFIER */
-#line 1857 "dtool/src/cppparser/cppBison.yxx"
-{
- yywarning("Not a type: " + (yyvsp[0].u.identifier)->get_fully_scoped_name(), (yylsp[0]));
- (yyval.u.type) = CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_unknown));
-}
-#line 5786 "built/tmp/cppBison.yxx.c"
- break;
-
- case 184: /* template_formal_parameter_type: TYPENAME_IDENTIFIER */
-#line 1862 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.type) = (yyvsp[0].u.identifier)->find_type(current_scope, global_scope, false, current_lexer);
- if ((yyval.u.type) == nullptr) {
- yyerror(string("internal error resolving type ") + (yyvsp[0].u.identifier)->get_fully_scoped_name(), (yylsp[0]));
- }
- assert((yyval.u.type) != nullptr);
-}
-#line 5798 "built/tmp/cppBison.yxx.c"
- break;
-
- case 185: /* template_formal_parameter_type: TYPEPACK_IDENTIFIER */
-#line 1870 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.type) = (yyvsp[0].u.identifier)->find_type(current_scope, global_scope, false, current_lexer);
- if ((yyval.u.type) == nullptr) {
- yyerror(string("internal error resolving type ") + (yyvsp[0].u.identifier)->get_fully_scoped_name(), (yylsp[0]));
- }
- assert((yyval.u.type) != nullptr);
-}
-#line 5810 "built/tmp/cppBison.yxx.c"
- break;
-
- case 186: /* instance_identifier: name_no_final optional_attributes */
-#line 1882 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = new CPPInstanceIdentifier((yyvsp[-1].u.identifier), (yyvsp[0].attr_list));
-}
-#line 5818 "built/tmp/cppBison.yxx.c"
- break;
-
- case 187: /* instance_identifier: KW_OPERATOR function_operator optional_attributes */
-#line 1886 "dtool/src/cppparser/cppBison.yxx"
-{
- // For an operator function. We implement this simply by building a
- // ficticious name for the function; in other respects it's just
- // like a regular function.
- CPPIdentifier *ident = (yyvsp[-2].u.identifier);
- if (ident == nullptr) {
- ident = new CPPIdentifier("operator "+(yyvsp[-1].str), (yylsp[-1]));
- } else {
- ident->_names.push_back("operator "+(yyvsp[-1].str));
- }
-
- (yyval.u.inst_ident) = new CPPInstanceIdentifier(ident, (yyvsp[0].attr_list));
-}
-#line 5836 "built/tmp/cppBison.yxx.c"
- break;
-
- case 188: /* instance_identifier: KW_OPERATOR SIMPLE_STRING IDENTIFIER optional_attributes */
-#line 1900 "dtool/src/cppparser/cppBison.yxx"
-{
- // A C++11 literal operator.
- if (!(yyvsp[-2].str).empty()) {
- yyerror("expected empty string", (yylsp[-2]));
- }
- CPPIdentifier *ident = (yyvsp[-3].u.identifier);
- if (ident == nullptr) {
- ident = new CPPIdentifier("operator \"\" "+(yyvsp[-1].u.identifier)->get_simple_name(), (yylsp[-1]));
- } else {
- ident->_names.push_back("operator \"\" "+(yyvsp[-1].u.identifier)->get_simple_name());
- }
-
- (yyval.u.inst_ident) = new CPPInstanceIdentifier(ident, (yyvsp[0].attr_list));
-}
-#line 5855 "built/tmp/cppBison.yxx.c"
- break;
-
- case 189: /* instance_identifier: KW_CONST instance_identifier */
-#line 1915 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_const);
-}
-#line 5864 "built/tmp/cppBison.yxx.c"
- break;
-
- case 190: /* instance_identifier: KW_VOLATILE instance_identifier */
-#line 1920 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_volatile);
-}
-#line 5873 "built/tmp/cppBison.yxx.c"
- break;
-
- case 191: /* instance_identifier: '*' optional_attributes instance_identifier */
-#line 1925 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_pointer, (yyvsp[-1].attr_list));
-}
-#line 5882 "built/tmp/cppBison.yxx.c"
- break;
-
- case 192: /* instance_identifier: '&' optional_attributes instance_identifier */
-#line 1930 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_reference, (yyvsp[-1].attr_list));
-}
-#line 5891 "built/tmp/cppBison.yxx.c"
- break;
-
- case 193: /* instance_identifier: ANDAND optional_attributes instance_identifier */
-#line 1935 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_rvalue_reference, (yyvsp[-1].attr_list));
-}
-#line 5900 "built/tmp/cppBison.yxx.c"
- break;
-
- case 194: /* instance_identifier: SCOPING '*' optional_attributes instance_identifier */
-#line 1940 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_scoped_pointer_modifier((yyvsp[-3].u.identifier), (yyvsp[-1].attr_list));
-}
-#line 5909 "built/tmp/cppBison.yxx.c"
- break;
-
- case 195: /* instance_identifier: instance_identifier '[' optional_const_expr ']' optional_attributes */
-#line 1945 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[-4].u.inst_ident);
- (yyval.u.inst_ident)->add_array_modifier((yyvsp[-2].u.expr), (yyvsp[0].attr_list));
-}
-#line 5918 "built/tmp/cppBison.yxx.c"
- break;
-
- case 196: /* instance_identifier: '(' instance_identifier ')' */
-#line 1950 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[-1].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_paren);
-}
-#line 5927 "built/tmp/cppBison.yxx.c"
- break;
-
- case 197: /* $@16: %empty */
-#line 1955 "dtool/src/cppparser/cppBison.yxx"
-{
- // Create a scope for this function (in case it is a function)
- CPPScope *scope = new CPPScope((yyvsp[-1].u.inst_ident)->get_scope(current_scope, global_scope),
- CPPNameComponent(""), V_private);
-
- // It still needs to be able to pick up any template arguments, if this is
- // a definition for a method template. Add a fake "using" declaration to
- // accomplish this.
- scope->_using.insert(current_scope);
-
- push_scope(scope);
-}
-#line 5944 "built/tmp/cppBison.yxx.c"
- break;
-
- case 198: /* instance_identifier: instance_identifier '(' $@16 formal_parameter_list ')' function_post optional_attributes */
-#line 1968 "dtool/src/cppparser/cppBison.yxx"
-{
- pop_scope();
- (yyval.u.inst_ident) = (yyvsp[-6].u.inst_ident);
- if ((yyvsp[-3].u.param_list)->is_parameter_expr() && (yyvsp[-1].u.integer) == 0) {
- // Oops, this must have been an instance declaration with a
- // parameter list, not a function prototype.
- (yyval.u.inst_ident)->add_initializer_modifier((yyvsp[-3].u.param_list));
- }
- else {
- // This was (probably) a function prototype.
- (yyval.u.inst_ident)->add_func_modifier((yyvsp[-3].u.param_list), (yyvsp[-1].u.integer), nullptr, (yyvsp[0].attr_list));
- }
-}
-#line 5962 "built/tmp/cppBison.yxx.c"
- break;
-
- case 199: /* instance_identifier_and_maybe_trailing_return_type: instance_identifier maybe_trailing_return_type */
-#line 1986 "dtool/src/cppparser/cppBison.yxx"
-{
- // This is handled a bit awkwardly right now. Ideally it'd be wrapped
- // up in the instance_identifier rule, but then more needs to happen in
- // order to avoid shift/reduce conflicts.
- if ((yyvsp[0].u.type) != nullptr) {
- (yyvsp[-1].u.inst_ident)->add_trailing_return_type((yyvsp[0].u.type));
- }
- (yyval.u.inst_ident) = (yyvsp[-1].u.inst_ident);
-}
-#line 5976 "built/tmp/cppBison.yxx.c"
- break;
-
- case 200: /* instance_identifier_and_maybe_trailing_return_type: instance_identifier ':' const_expr */
-#line 1996 "dtool/src/cppparser/cppBison.yxx"
-{
- // Bitfield definition.
- (yyvsp[-2].u.inst_ident)->_bit_width = (yyvsp[0].u.expr);
- (yyval.u.inst_ident) = (yyvsp[-2].u.inst_ident);
-}
-#line 5986 "built/tmp/cppBison.yxx.c"
- break;
-
- case 201: /* maybe_trailing_return_type: empty */
-#line 2006 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.type) = nullptr;
-}
-#line 5994 "built/tmp/cppBison.yxx.c"
- break;
-
- case 202: /* maybe_trailing_return_type: POINTSAT predefined_type empty_instance_identifier */
-#line 2010 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.type) = (yyvsp[0].u.inst_ident)->unroll_type((yyvsp[-1].u.type));
-}
-#line 6002 "built/tmp/cppBison.yxx.c"
- break;
-
- case 203: /* maybe_trailing_return_type: POINTSAT KW_CONST predefined_type empty_instance_identifier */
-#line 2014 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyvsp[0].u.inst_ident)->add_modifier(IIT_const);
- (yyval.u.type) = (yyvsp[0].u.inst_ident)->unroll_type((yyvsp[-1].u.type));
-}
-#line 6011 "built/tmp/cppBison.yxx.c"
- break;
-
- case 204: /* maybe_comma_identifier: empty */
-#line 2023 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.identifier) = nullptr;
-}
-#line 6019 "built/tmp/cppBison.yxx.c"
- break;
-
- case 205: /* maybe_comma_identifier: ',' IDENTIFIER */
-#line 2027 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.identifier) = (yyvsp[0].u.identifier);
-}
-#line 6027 "built/tmp/cppBison.yxx.c"
- break;
-
- case 206: /* function_parameter_list: empty */
-#line 2035 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.param_list) = new CPPParameterList;
-}
-#line 6035 "built/tmp/cppBison.yxx.c"
- break;
-
- case 207: /* function_parameter_list: ELLIPSIS */
-#line 2039 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.param_list) = new CPPParameterList;
- (yyval.u.param_list)->_includes_ellipsis = true;
-}
-#line 6044 "built/tmp/cppBison.yxx.c"
- break;
-
- case 208: /* function_parameter_list: function_parameters */
-#line 2044 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.param_list) = (yyvsp[0].u.param_list);
-}
-#line 6052 "built/tmp/cppBison.yxx.c"
- break;
-
- case 209: /* function_parameter_list: function_parameters ',' ELLIPSIS */
-#line 2048 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.param_list) = (yyvsp[-2].u.param_list);
- (yyval.u.param_list)->_includes_ellipsis = true;
-}
-#line 6061 "built/tmp/cppBison.yxx.c"
- break;
-
- case 210: /* function_parameter_list: function_parameters ELLIPSIS */
-#line 2053 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.param_list) = (yyvsp[-1].u.param_list);
- (yyval.u.param_list)->_includes_ellipsis = true;
-}
-#line 6070 "built/tmp/cppBison.yxx.c"
- break;
-
- case 211: /* function_parameters: function_parameter */
-#line 2061 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.param_list) = new CPPParameterList;
- (yyval.u.param_list)->_parameters.push_back((yyvsp[0].u.instance));
-}
-#line 6079 "built/tmp/cppBison.yxx.c"
- break;
-
- case 212: /* function_parameters: function_parameters ',' function_parameter */
-#line 2066 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.param_list) = (yyvsp[-2].u.param_list);
- (yyval.u.param_list)->_parameters.push_back((yyvsp[0].u.instance));
-}
-#line 6088 "built/tmp/cppBison.yxx.c"
- break;
-
- case 213: /* formal_parameter_list: empty */
-#line 2074 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.param_list) = new CPPParameterList;
-}
-#line 6096 "built/tmp/cppBison.yxx.c"
- break;
-
- case 214: /* formal_parameter_list: ELLIPSIS */
-#line 2078 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.param_list) = new CPPParameterList;
- (yyval.u.param_list)->_includes_ellipsis = true;
-}
-#line 6105 "built/tmp/cppBison.yxx.c"
- break;
-
- case 215: /* formal_parameter_list: formal_parameters */
-#line 2083 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.param_list) = (yyvsp[0].u.param_list);
-}
-#line 6113 "built/tmp/cppBison.yxx.c"
- break;
-
- case 216: /* formal_parameter_list: formal_parameters ',' ELLIPSIS */
-#line 2087 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.param_list) = (yyvsp[-2].u.param_list);
- (yyval.u.param_list)->_includes_ellipsis = true;
-}
-#line 6122 "built/tmp/cppBison.yxx.c"
- break;
-
- case 217: /* formal_parameter_list: formal_parameters ELLIPSIS */
-#line 2092 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.param_list) = (yyvsp[-1].u.param_list);
- (yyval.u.param_list)->_includes_ellipsis = true;
-}
-#line 6131 "built/tmp/cppBison.yxx.c"
- break;
-
- case 218: /* formal_parameters: formal_parameter */
-#line 2100 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.param_list) = new CPPParameterList;
- (yyval.u.param_list)->_parameters.push_back((yyvsp[0].u.instance));
-}
-#line 6140 "built/tmp/cppBison.yxx.c"
- break;
-
- case 219: /* formal_parameters: formal_parameters ',' formal_parameter */
-#line 2105 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.param_list) = (yyvsp[-2].u.param_list);
- (yyval.u.param_list)->_parameters.push_back((yyvsp[0].u.instance));
-}
-#line 6149 "built/tmp/cppBison.yxx.c"
- break;
-
- case 220: /* template_parameter_maybe_initialize: empty */
-#line 2113 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = nullptr;
-}
-#line 6157 "built/tmp/cppBison.yxx.c"
- break;
-
- case 221: /* template_parameter_maybe_initialize: '=' no_angle_bracket_const_expr */
-#line 2117 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = (yyvsp[0].u.expr);
-}
-#line 6165 "built/tmp/cppBison.yxx.c"
- break;
-
- case 222: /* maybe_initialize: empty */
-#line 2124 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = nullptr;
-}
-#line 6173 "built/tmp/cppBison.yxx.c"
- break;
-
- case 223: /* maybe_initialize: '=' const_expr */
-#line 2128 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = (yyvsp[0].u.expr);
-}
-#line 6181 "built/tmp/cppBison.yxx.c"
- break;
-
- case 224: /* maybe_initialize_or_constructor_body: ';' */
-#line 2135 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = nullptr;
-}
-#line 6189 "built/tmp/cppBison.yxx.c"
- break;
-
- case 225: /* maybe_initialize_or_constructor_body: '{' code '}' */
-#line 2139 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = nullptr;
-}
-#line 6197 "built/tmp/cppBison.yxx.c"
- break;
-
- case 226: /* maybe_initialize_or_constructor_body: ':' constructor_inits '{' code '}' */
-#line 2143 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = nullptr;
-}
-#line 6205 "built/tmp/cppBison.yxx.c"
- break;
-
- case 227: /* maybe_initialize_or_constructor_body: '=' KW_DEFAULT ';' */
-#line 2147 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::get_default());
-}
-#line 6213 "built/tmp/cppBison.yxx.c"
- break;
-
- case 228: /* maybe_initialize_or_constructor_body: '=' KW_DELETE ';' */
-#line 2151 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::get_delete());
-}
-#line 6221 "built/tmp/cppBison.yxx.c"
- break;
-
- case 229: /* maybe_initialize_or_function_body: ';' */
-#line 2158 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = nullptr;
-}
-#line 6229 "built/tmp/cppBison.yxx.c"
- break;
-
- case 230: /* maybe_initialize_or_function_body: '{' code '}' */
-#line 2162 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = nullptr;
-}
-#line 6237 "built/tmp/cppBison.yxx.c"
- break;
-
- case 231: /* maybe_initialize_or_function_body: '=' const_expr ';' */
-#line 2166 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = (yyvsp[-1].u.expr);
-}
-#line 6245 "built/tmp/cppBison.yxx.c"
- break;
-
- case 232: /* maybe_initialize_or_function_body: '=' KW_DEFAULT ';' */
-#line 2170 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::get_default());
-}
-#line 6253 "built/tmp/cppBison.yxx.c"
- break;
-
- case 233: /* maybe_initialize_or_function_body: '=' KW_DELETE ';' */
-#line 2174 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::get_delete());
-}
-#line 6261 "built/tmp/cppBison.yxx.c"
- break;
-
- case 234: /* maybe_initialize_or_function_body: '=' '{' structure_init '}' */
-#line 2178 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = nullptr;
-}
-#line 6269 "built/tmp/cppBison.yxx.c"
- break;
-
- case 238: /* structure_init_body: const_expr */
-#line 2191 "dtool/src/cppparser/cppBison.yxx"
-{
-}
-#line 6276 "built/tmp/cppBison.yxx.c"
- break;
-
- case 242: /* function_parameter: optional_attributes storage_class type formal_parameter_identifier maybe_initialize */
-#line 2200 "dtool/src/cppparser/cppBison.yxx"
-{
- if ((yyvsp[-3].u.integer) & CPPInstance::SC_const) {
- (yyvsp[-1].u.inst_ident)->add_modifier(IIT_const);
- }
- if ((yyvsp[-3].u.integer) & CPPInstance::SC_volatile) {
- (yyvsp[-1].u.inst_ident)->add_modifier(IIT_volatile);
- }
- (yyvsp[-1].u.inst_ident)->add_attributes((yyvsp[-4].attr_list));
- (yyval.u.instance) = new CPPInstance((yyvsp[-2].u.type), (yyvsp[-1].u.inst_ident), 0, (yylsp[-1]).file);
- (yyval.u.instance)->set_initializer((yyvsp[0].u.expr));
-}
-#line 6292 "built/tmp/cppBison.yxx.c"
- break;
-
- case 243: /* function_parameter: optional_attributes storage_class type_pack parameter_pack_identifier maybe_initialize */
-#line 2212 "dtool/src/cppparser/cppBison.yxx"
-{
- if ((yyvsp[-3].u.integer) & CPPInstance::SC_const) {
- (yyvsp[-1].u.inst_ident)->add_modifier(IIT_const);
- }
- if ((yyvsp[-3].u.integer) & CPPInstance::SC_volatile) {
- (yyvsp[-1].u.inst_ident)->add_modifier(IIT_volatile);
- }
- (yyvsp[-1].u.inst_ident)->add_attributes((yyvsp[-4].attr_list));
- (yyval.u.instance) = new CPPInstance((yyvsp[-2].u.type), (yyvsp[-1].u.inst_ident), 0, (yylsp[-1]).file);
- (yyval.u.instance)->set_initializer((yyvsp[0].u.expr));
-}
-#line 6308 "built/tmp/cppBison.yxx.c"
- break;
-
- case 244: /* formal_parameter: function_parameter */
-#line 2231 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.instance) = (yyvsp[0].u.instance);
-}
-#line 6316 "built/tmp/cppBison.yxx.c"
- break;
-
- case 245: /* formal_parameter: formal_const_expr */
-#line 2235 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPType *type =
- CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_parameter));
- (yyval.u.instance) = new CPPInstance(type, "expr");
- (yyval.u.instance)->set_initializer((yyvsp[0].u.expr));
-}
-#line 6327 "built/tmp/cppBison.yxx.c"
- break;
-
- case 246: /* not_paren_formal_parameter_identifier: empty */
-#line 2245 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = new CPPInstanceIdentifier(nullptr);
-}
-#line 6335 "built/tmp/cppBison.yxx.c"
- break;
-
- case 247: /* not_paren_formal_parameter_identifier: name_no_final optional_attributes */
-#line 2249 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = new CPPInstanceIdentifier((yyvsp[-1].u.identifier), (yyvsp[0].attr_list));
-}
-#line 6343 "built/tmp/cppBison.yxx.c"
- break;
-
- case 248: /* not_paren_formal_parameter_identifier: KW_CONST not_paren_formal_parameter_identifier */
-#line 2253 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_const);
-}
-#line 6352 "built/tmp/cppBison.yxx.c"
- break;
-
- case 249: /* not_paren_formal_parameter_identifier: KW_VOLATILE not_paren_formal_parameter_identifier */
-#line 2258 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_volatile);
-}
-#line 6361 "built/tmp/cppBison.yxx.c"
- break;
-
- case 250: /* not_paren_formal_parameter_identifier: KW_RESTRICT not_paren_formal_parameter_identifier */
-#line 2263 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_restrict);
-}
-#line 6370 "built/tmp/cppBison.yxx.c"
- break;
-
- case 251: /* not_paren_formal_parameter_identifier: '*' optional_attributes not_paren_formal_parameter_identifier */
-#line 2268 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_pointer, (yyvsp[-1].attr_list));
-}
-#line 6379 "built/tmp/cppBison.yxx.c"
- break;
-
- case 252: /* not_paren_formal_parameter_identifier: '&' optional_attributes not_paren_formal_parameter_identifier */
-#line 2273 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_reference, (yyvsp[-1].attr_list));
-}
-#line 6388 "built/tmp/cppBison.yxx.c"
- break;
-
- case 253: /* not_paren_formal_parameter_identifier: ANDAND optional_attributes not_paren_formal_parameter_identifier */
-#line 2278 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_rvalue_reference, (yyvsp[-1].attr_list));
-}
-#line 6397 "built/tmp/cppBison.yxx.c"
- break;
-
- case 254: /* not_paren_formal_parameter_identifier: SCOPING '*' optional_attributes not_paren_formal_parameter_identifier */
-#line 2283 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_scoped_pointer_modifier((yyvsp[-3].u.identifier), (yyvsp[-1].attr_list));
-}
-#line 6406 "built/tmp/cppBison.yxx.c"
- break;
-
- case 255: /* not_paren_formal_parameter_identifier: not_paren_formal_parameter_identifier '[' optional_const_expr ']' optional_attributes */
-#line 2288 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[-4].u.inst_ident);
- (yyval.u.inst_ident)->add_array_modifier((yyvsp[-2].u.expr), (yyvsp[0].attr_list));
-}
-#line 6415 "built/tmp/cppBison.yxx.c"
- break;
-
- case 256: /* formal_parameter_identifier: empty */
-#line 2296 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = new CPPInstanceIdentifier(nullptr);
-}
-#line 6423 "built/tmp/cppBison.yxx.c"
- break;
-
- case 257: /* formal_parameter_identifier: name_no_final optional_attributes */
-#line 2300 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = new CPPInstanceIdentifier((yyvsp[-1].u.identifier), (yyvsp[0].attr_list));
-}
-#line 6431 "built/tmp/cppBison.yxx.c"
- break;
-
- case 258: /* formal_parameter_identifier: KW_CONST formal_parameter_identifier */
-#line 2304 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_const);
-}
-#line 6440 "built/tmp/cppBison.yxx.c"
- break;
-
- case 259: /* formal_parameter_identifier: KW_VOLATILE formal_parameter_identifier */
-#line 2309 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_volatile);
-}
-#line 6449 "built/tmp/cppBison.yxx.c"
- break;
-
- case 260: /* formal_parameter_identifier: KW_RESTRICT formal_parameter_identifier */
-#line 2314 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_restrict);
-}
-#line 6458 "built/tmp/cppBison.yxx.c"
- break;
-
- case 261: /* formal_parameter_identifier: '*' optional_attributes formal_parameter_identifier */
-#line 2319 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_pointer, (yyvsp[-1].attr_list));
-}
-#line 6467 "built/tmp/cppBison.yxx.c"
- break;
-
- case 262: /* formal_parameter_identifier: '&' optional_attributes formal_parameter_identifier */
-#line 2324 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_reference, (yyvsp[-1].attr_list));
-}
-#line 6476 "built/tmp/cppBison.yxx.c"
- break;
-
- case 263: /* formal_parameter_identifier: ANDAND optional_attributes formal_parameter_identifier */
-#line 2329 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_rvalue_reference, (yyvsp[-1].attr_list));
-}
-#line 6485 "built/tmp/cppBison.yxx.c"
- break;
-
- case 264: /* formal_parameter_identifier: SCOPING '*' optional_attributes formal_parameter_identifier */
-#line 2334 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_scoped_pointer_modifier((yyvsp[-3].u.identifier), (yyvsp[-1].attr_list));
-}
-#line 6494 "built/tmp/cppBison.yxx.c"
- break;
-
- case 265: /* formal_parameter_identifier: formal_parameter_identifier '[' optional_const_expr ']' optional_attributes */
-#line 2339 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[-4].u.inst_ident);
- (yyval.u.inst_ident)->add_array_modifier((yyvsp[-2].u.expr), (yyvsp[0].attr_list));
-}
-#line 6503 "built/tmp/cppBison.yxx.c"
- break;
-
- case 266: /* formal_parameter_identifier: '(' formal_parameter_identifier ')' '(' function_parameter_list ')' function_post optional_attributes */
-#line 2344 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[-6].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_paren);
- (yyval.u.inst_ident)->add_func_modifier((yyvsp[-3].u.param_list), (yyvsp[-1].u.integer), nullptr, (yyvsp[0].attr_list));
-}
-#line 6513 "built/tmp/cppBison.yxx.c"
- break;
-
- case 267: /* formal_parameter_identifier: '(' formal_parameter_identifier ')' */
-#line 2350 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[-1].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_paren);
-}
-#line 6522 "built/tmp/cppBison.yxx.c"
- break;
-
- case 268: /* parameter_pack_identifier: ELLIPSIS */
-#line 2358 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = new CPPInstanceIdentifier(nullptr);
- (yyval.u.inst_ident)->_packed = true;
-}
-#line 6531 "built/tmp/cppBison.yxx.c"
- break;
-
- case 269: /* parameter_pack_identifier: ELLIPSIS name optional_attributes */
-#line 2363 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = new CPPInstanceIdentifier((yyvsp[-1].u.identifier), (yyvsp[0].attr_list));
- (yyval.u.inst_ident)->_packed = true;
-}
-#line 6540 "built/tmp/cppBison.yxx.c"
- break;
-
- case 270: /* parameter_pack_identifier: KW_CONST parameter_pack_identifier */
-#line 2368 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_const);
-}
-#line 6549 "built/tmp/cppBison.yxx.c"
- break;
-
- case 271: /* parameter_pack_identifier: KW_VOLATILE parameter_pack_identifier */
-#line 2373 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_volatile);
-}
-#line 6558 "built/tmp/cppBison.yxx.c"
- break;
-
- case 272: /* parameter_pack_identifier: KW_RESTRICT parameter_pack_identifier */
-#line 2378 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_restrict);
-}
-#line 6567 "built/tmp/cppBison.yxx.c"
- break;
-
- case 273: /* parameter_pack_identifier: '*' optional_attributes parameter_pack_identifier */
-#line 2383 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_pointer, (yyvsp[-1].attr_list));
-}
-#line 6576 "built/tmp/cppBison.yxx.c"
- break;
-
- case 274: /* parameter_pack_identifier: '&' optional_attributes parameter_pack_identifier */
-#line 2388 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_reference, (yyvsp[-1].attr_list));
-}
-#line 6585 "built/tmp/cppBison.yxx.c"
- break;
-
- case 275: /* parameter_pack_identifier: ANDAND optional_attributes parameter_pack_identifier */
-#line 2393 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_rvalue_reference, (yyvsp[-1].attr_list));
-}
-#line 6594 "built/tmp/cppBison.yxx.c"
- break;
-
- case 276: /* parameter_pack_identifier: SCOPING '*' optional_attributes parameter_pack_identifier */
-#line 2398 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_scoped_pointer_modifier((yyvsp[-3].u.identifier), (yyvsp[-1].attr_list));
-}
-#line 6603 "built/tmp/cppBison.yxx.c"
- break;
-
- case 277: /* parameter_pack_identifier: parameter_pack_identifier '[' optional_const_expr ']' optional_attributes */
-#line 2403 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[-4].u.inst_ident);
- (yyval.u.inst_ident)->add_array_modifier((yyvsp[-2].u.expr), (yyvsp[0].attr_list));
-}
-#line 6612 "built/tmp/cppBison.yxx.c"
- break;
-
- case 278: /* parameter_pack_identifier: '(' parameter_pack_identifier ')' '(' function_parameter_list ')' function_post optional_attributes */
-#line 2408 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[-6].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_paren);
- (yyval.u.inst_ident)->add_func_modifier((yyvsp[-3].u.param_list), (yyvsp[-1].u.integer), nullptr, (yyvsp[0].attr_list));
-}
-#line 6622 "built/tmp/cppBison.yxx.c"
- break;
-
- case 279: /* parameter_pack_identifier: '(' parameter_pack_identifier ')' */
-#line 2414 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[-1].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_paren);
-}
-#line 6631 "built/tmp/cppBison.yxx.c"
- break;
-
- case 280: /* not_paren_empty_instance_identifier: empty */
-#line 2422 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = new CPPInstanceIdentifier(nullptr);
-}
-#line 6639 "built/tmp/cppBison.yxx.c"
- break;
-
- case 281: /* not_paren_empty_instance_identifier: ELLIPSIS */
-#line 2426 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = new CPPInstanceIdentifier(nullptr);
- (yyval.u.inst_ident)->_packed = true;
-}
-#line 6648 "built/tmp/cppBison.yxx.c"
- break;
-
- case 282: /* not_paren_empty_instance_identifier: ELLIPSIS name optional_attributes */
-#line 2431 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = new CPPInstanceIdentifier((yyvsp[-1].u.identifier), (yyvsp[0].attr_list));
- (yyval.u.inst_ident)->_packed = true;
-}
-#line 6657 "built/tmp/cppBison.yxx.c"
- break;
-
- case 283: /* not_paren_empty_instance_identifier: KW_CONST not_paren_empty_instance_identifier */
-#line 2436 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_const);
-}
-#line 6666 "built/tmp/cppBison.yxx.c"
- break;
-
- case 284: /* not_paren_empty_instance_identifier: KW_VOLATILE not_paren_empty_instance_identifier */
-#line 2441 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_volatile);
-}
-#line 6675 "built/tmp/cppBison.yxx.c"
- break;
-
- case 285: /* not_paren_empty_instance_identifier: KW_RESTRICT not_paren_empty_instance_identifier */
-#line 2446 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_restrict);
-}
-#line 6684 "built/tmp/cppBison.yxx.c"
- break;
-
- case 286: /* not_paren_empty_instance_identifier: '*' optional_attributes not_paren_empty_instance_identifier */
-#line 2451 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_pointer, (yyvsp[-1].attr_list));
-}
-#line 6693 "built/tmp/cppBison.yxx.c"
- break;
-
- case 287: /* not_paren_empty_instance_identifier: '&' optional_attributes not_paren_empty_instance_identifier */
-#line 2456 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_reference, (yyvsp[-1].attr_list));
-}
-#line 6702 "built/tmp/cppBison.yxx.c"
- break;
-
- case 288: /* not_paren_empty_instance_identifier: ANDAND optional_attributes not_paren_empty_instance_identifier */
-#line 2461 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_rvalue_reference, (yyvsp[-1].attr_list));
-}
-#line 6711 "built/tmp/cppBison.yxx.c"
- break;
-
- case 289: /* not_paren_empty_instance_identifier: SCOPING '*' optional_attributes not_paren_empty_instance_identifier */
-#line 2466 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_scoped_pointer_modifier((yyvsp[-3].u.identifier), (yyvsp[-1].attr_list));
-}
-#line 6720 "built/tmp/cppBison.yxx.c"
- break;
-
- case 290: /* not_paren_empty_instance_identifier: not_paren_empty_instance_identifier '[' optional_const_expr ']' optional_attributes */
-#line 2471 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[-4].u.inst_ident);
- (yyval.u.inst_ident)->add_array_modifier((yyvsp[-2].u.expr), (yyvsp[0].attr_list));
-}
-#line 6729 "built/tmp/cppBison.yxx.c"
- break;
-
- case 291: /* empty_instance_identifier: empty */
-#line 2479 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = new CPPInstanceIdentifier(nullptr);
-}
-#line 6737 "built/tmp/cppBison.yxx.c"
- break;
-
- case 292: /* empty_instance_identifier: ELLIPSIS */
-#line 2483 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = new CPPInstanceIdentifier(nullptr);
- (yyval.u.inst_ident)->_packed = true;
-}
-#line 6746 "built/tmp/cppBison.yxx.c"
- break;
-
- case 293: /* empty_instance_identifier: ELLIPSIS name optional_attributes */
-#line 2488 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = new CPPInstanceIdentifier((yyvsp[-1].u.identifier), (yyvsp[0].attr_list));
- (yyval.u.inst_ident)->_packed = true;
-}
-#line 6755 "built/tmp/cppBison.yxx.c"
- break;
-
- case 294: /* empty_instance_identifier: KW_CONST empty_instance_identifier */
-#line 2493 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_const);
-}
-#line 6764 "built/tmp/cppBison.yxx.c"
- break;
-
- case 295: /* empty_instance_identifier: KW_VOLATILE empty_instance_identifier */
-#line 2498 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_volatile);
-}
-#line 6773 "built/tmp/cppBison.yxx.c"
- break;
-
- case 296: /* empty_instance_identifier: KW_RESTRICT empty_instance_identifier */
-#line 2503 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_restrict);
-}
-#line 6782 "built/tmp/cppBison.yxx.c"
- break;
-
- case 297: /* empty_instance_identifier: '*' optional_attributes not_paren_empty_instance_identifier */
-#line 2508 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_pointer, (yyvsp[-1].attr_list));
-}
-#line 6791 "built/tmp/cppBison.yxx.c"
- break;
-
- case 298: /* empty_instance_identifier: '&' optional_attributes not_paren_empty_instance_identifier */
-#line 2513 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_reference, (yyvsp[-1].attr_list));
-}
-#line 6800 "built/tmp/cppBison.yxx.c"
- break;
-
- case 299: /* empty_instance_identifier: ANDAND optional_attributes not_paren_empty_instance_identifier */
-#line 2518 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_rvalue_reference, (yyvsp[-1].attr_list));
-}
-#line 6809 "built/tmp/cppBison.yxx.c"
- break;
-
- case 300: /* empty_instance_identifier: SCOPING '*' optional_attributes not_paren_empty_instance_identifier */
-#line 2523 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[0].u.inst_ident);
- (yyval.u.inst_ident)->add_scoped_pointer_modifier((yyvsp[-3].u.identifier), (yyvsp[-1].attr_list));
-}
-#line 6818 "built/tmp/cppBison.yxx.c"
- break;
-
- case 301: /* empty_instance_identifier: not_paren_empty_instance_identifier '[' optional_const_expr ']' optional_attributes */
-#line 2528 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[-4].u.inst_ident);
- (yyval.u.inst_ident)->add_array_modifier((yyvsp[-2].u.expr), (yyvsp[0].attr_list));
-}
-#line 6827 "built/tmp/cppBison.yxx.c"
- break;
-
- case 302: /* empty_instance_identifier: '(' function_parameter_list ')' function_post optional_attributes maybe_trailing_return_type */
-#line 2533 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = new CPPInstanceIdentifier(nullptr);
- (yyval.u.inst_ident)->add_modifier(IIT_paren);
- (yyval.u.inst_ident)->add_func_modifier((yyvsp[-4].u.param_list), (yyvsp[-2].u.integer), (yyvsp[0].u.type), (yyvsp[-1].attr_list));
-}
-#line 6837 "built/tmp/cppBison.yxx.c"
- break;
-
- case 303: /* empty_instance_identifier: '(' '*' optional_attributes not_paren_empty_instance_identifier ')' '(' function_parameter_list ')' function_post optional_attributes maybe_trailing_return_type */
-#line 2539 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[-7].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_pointer, (yyvsp[-8].attr_list));
- (yyval.u.inst_ident)->add_modifier(IIT_paren);
- (yyval.u.inst_ident)->add_func_modifier((yyvsp[-4].u.param_list), (yyvsp[-2].u.integer), (yyvsp[0].u.type), (yyvsp[-1].attr_list));
-}
-#line 6848 "built/tmp/cppBison.yxx.c"
- break;
-
- case 304: /* empty_instance_identifier: '(' '&' optional_attributes not_paren_empty_instance_identifier ')' '(' function_parameter_list ')' function_post optional_attributes maybe_trailing_return_type */
-#line 2546 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[-7].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_reference, (yyvsp[-8].attr_list));
- (yyval.u.inst_ident)->add_modifier(IIT_paren);
- (yyval.u.inst_ident)->add_func_modifier((yyvsp[-4].u.param_list), (yyvsp[-2].u.integer), (yyvsp[0].u.type), (yyvsp[-1].attr_list));
-}
-#line 6859 "built/tmp/cppBison.yxx.c"
- break;
-
- case 305: /* empty_instance_identifier: '(' ANDAND optional_attributes not_paren_empty_instance_identifier ')' '(' function_parameter_list ')' function_post optional_attributes maybe_trailing_return_type */
-#line 2553 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.inst_ident) = (yyvsp[-7].u.inst_ident);
- (yyval.u.inst_ident)->add_modifier(IIT_rvalue_reference, (yyvsp[-8].attr_list));
- (yyval.u.inst_ident)->add_modifier(IIT_paren);
- (yyval.u.inst_ident)->add_func_modifier((yyvsp[-4].u.param_list), (yyvsp[-2].u.integer), (yyvsp[0].u.type), (yyvsp[-1].attr_list));
-}
-#line 6870 "built/tmp/cppBison.yxx.c"
- break;
-
- case 306: /* type: simple_type */
-#line 2563 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.type) = CPPType::new_type((yyvsp[0].u.simple_type));
-}
-#line 6878 "built/tmp/cppBison.yxx.c"
- break;
-
- case 307: /* type: TYPENAME_IDENTIFIER */
-#line 2567 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.type) = (yyvsp[0].u.identifier)->find_type(current_scope, global_scope, false, current_lexer);
- if ((yyval.u.type) == nullptr) {
- yyerror(string("internal error resolving type ") + (yyvsp[0].u.identifier)->get_fully_scoped_name(), (yylsp[0]));
- }
- assert((yyval.u.type) != nullptr);
-}
-#line 6890 "built/tmp/cppBison.yxx.c"
- break;
-
- case 308: /* type: KW_TYPENAME name */
-#line 2575 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.type) = CPPType::new_type(new CPPTBDType((yyvsp[0].u.identifier)));
-}
-#line 6898 "built/tmp/cppBison.yxx.c"
- break;
-
- case 309: /* type: anonymous_struct */
-#line 2579 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.type) = CPPType::new_type((yyvsp[0].u.struct_type));
-}
-#line 6906 "built/tmp/cppBison.yxx.c"
- break;
-
- case 310: /* type: named_struct */
-#line 2583 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.type) = CPPType::new_type((yyvsp[0].u.struct_type));
-}
-#line 6914 "built/tmp/cppBison.yxx.c"
- break;
-
- case 311: /* type: enum */
-#line 2587 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.type) = CPPType::new_type((yyvsp[0].u.enum_type));
-}
-#line 6922 "built/tmp/cppBison.yxx.c"
- break;
-
- case 312: /* type: struct_keyword optional_attributes name */
-#line 2591 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPType *type = (yyvsp[0].u.identifier)->find_type(current_scope, global_scope, false, current_lexer);
- if (type != nullptr) {
- (yyval.u.type) = type;
- } else {
- CPPExtensionType *et =
- CPPType::new_type(new CPPExtensionType((yyvsp[-2].u.extension_enum), (yyvsp[0].u.identifier), current_scope, (yylsp[-2]).file, (yyvsp[-1].attr_list)))
- ->as_extension_type();
- CPPScope *scope = (yyvsp[0].u.identifier)->get_scope(current_scope, global_scope);
- if (scope != nullptr) {
- scope->define_extension_type(et);
- }
- (yyval.u.type) = et;
- }
-}
-#line 6942 "built/tmp/cppBison.yxx.c"
- break;
-
- case 313: /* type: enum_keyword optional_attributes name_no_final ':' enum_element_type */
-#line 2607 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPType *type = (yyvsp[-2].u.identifier)->find_type(current_scope, global_scope, false, current_lexer);
- if (type != nullptr) {
- (yyval.u.type) = type;
- } else {
- CPPExtensionType *et =
- CPPType::new_type(new CPPExtensionType((yyvsp[-4].u.extension_enum), (yyvsp[-2].u.identifier), current_scope, (yylsp[-4]).file, (yyvsp[-3].attr_list)))
- ->as_extension_type();
- CPPScope *scope = (yyvsp[-2].u.identifier)->get_scope(current_scope, global_scope);
- if (scope != nullptr) {
- scope->define_extension_type(et);
- }
- (yyval.u.type) = et;
- }
-}
-#line 6962 "built/tmp/cppBison.yxx.c"
- break;
-
- case 314: /* type: KW_DECLTYPE '(' const_expr ')' */
-#line 2623 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.type) = (yyvsp[-1].u.expr)->determine_type();
- if ((yyval.u.type) == nullptr) {
- stringstream str;
- str << *(yyvsp[-1].u.expr);
- yyerror("could not determine type of " + str.str(), (yylsp[-1]));
- }
-}
-#line 6975 "built/tmp/cppBison.yxx.c"
- break;
-
- case 315: /* type: KW_DECLTYPE '(' KW_AUTO ')' */
-#line 2632 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.type) = CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_auto));
-}
-#line 6983 "built/tmp/cppBison.yxx.c"
- break;
-
- case 316: /* type: KW_UNDERLYING_TYPE '(' full_type ')' */
-#line 2636 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPEnumType *enum_type = (yyvsp[-1].u.type)->as_enum_type();
- if (enum_type == nullptr) {
- yyerror("an enumeration type is required", (yylsp[-1]));
- (yyval.u.type) = (yyvsp[-1].u.type);
- } else {
- (yyval.u.type) = enum_type->get_underlying_type();
- }
-}
-#line 6997 "built/tmp/cppBison.yxx.c"
- break;
-
- case 317: /* type: KW_AUTO */
-#line 2646 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.type) = CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_auto));
-}
-#line 7005 "built/tmp/cppBison.yxx.c"
- break;
-
- case 318: /* type: KW_BUILTIN_VA_LIST */
-#line 2650 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.type) = CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_va_list));
-}
-#line 7013 "built/tmp/cppBison.yxx.c"
- break;
-
- case 319: /* type_pack: TYPEPACK_IDENTIFIER */
-#line 2657 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.type) = (yyvsp[0].u.identifier)->find_type(current_scope, global_scope, false, current_lexer);
- if ((yyval.u.type) == nullptr) {
- yyerror(string("internal error resolving type ") + (yyvsp[0].u.identifier)->get_fully_scoped_name(), (yylsp[0]));
- }
- assert((yyval.u.type) != nullptr);
-}
-#line 7025 "built/tmp/cppBison.yxx.c"
- break;
-
- case 320: /* type_decl: simple_type */
-#line 2668 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.decl) = CPPType::new_type((yyvsp[0].u.simple_type));
-}
-#line 7033 "built/tmp/cppBison.yxx.c"
- break;
-
- case 321: /* type_decl: TYPENAME_IDENTIFIER */
-#line 2672 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.decl) = (yyvsp[0].u.identifier)->find_type(current_scope, global_scope, false, current_lexer);
- if ((yyval.u.decl) == nullptr) {
- yyerror(string("internal error resolving type ") + (yyvsp[0].u.identifier)->get_fully_scoped_name(), (yylsp[0]));
- }
- assert((yyval.u.decl) != nullptr);
-}
-#line 7045 "built/tmp/cppBison.yxx.c"
- break;
-
- case 322: /* type_decl: KW_TYPENAME name */
-#line 2680 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.decl) = CPPType::new_type(new CPPTBDType((yyvsp[0].u.identifier)));
-}
-#line 7053 "built/tmp/cppBison.yxx.c"
- break;
-
- case 323: /* type_decl: anonymous_struct */
-#line 2684 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.decl) = CPPType::new_type((yyvsp[0].u.struct_type));
-}
-#line 7061 "built/tmp/cppBison.yxx.c"
- break;
-
- case 324: /* type_decl: named_struct */
-#line 2688 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.decl) = new CPPTypeDeclaration(CPPType::new_type((yyvsp[0].u.struct_type)));
-}
-#line 7069 "built/tmp/cppBison.yxx.c"
- break;
-
- case 325: /* type_decl: enum */
-#line 2692 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.decl) = new CPPTypeDeclaration(CPPType::new_type((yyvsp[0].u.enum_type)));
-}
-#line 7077 "built/tmp/cppBison.yxx.c"
- break;
-
- case 326: /* type_decl: struct_keyword optional_attributes name */
-#line 2696 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPType *type = (yyvsp[0].u.identifier)->find_type(current_scope, global_scope, false, current_lexer);
- if (type != nullptr) {
- (yyval.u.decl) = type;
- } else {
- CPPExtensionType *et =
- CPPType::new_type(new CPPExtensionType((yyvsp[-2].u.extension_enum), (yyvsp[0].u.identifier), current_scope, (yylsp[-2]).file, (yyvsp[-1].attr_list)))
- ->as_extension_type();
- CPPScope *scope = (yyvsp[0].u.identifier)->get_scope(current_scope, global_scope);
- if (scope != nullptr) {
- scope->define_extension_type(et);
- }
- (yyval.u.decl) = et;
- }
-}
-#line 7097 "built/tmp/cppBison.yxx.c"
- break;
-
- case 327: /* type_decl: enum_keyword optional_attributes name_no_final ':' enum_element_type */
-#line 2712 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPType *type = (yyvsp[-2].u.identifier)->find_type(current_scope, global_scope, false, current_lexer);
- if (type != nullptr) {
- (yyval.u.decl) = type;
- } else {
- CPPExtensionType *et =
- CPPType::new_type(new CPPExtensionType((yyvsp[-4].u.extension_enum), (yyvsp[-2].u.identifier), current_scope, (yylsp[-4]).file, (yyvsp[-3].attr_list)))
- ->as_extension_type();
- CPPScope *scope = (yyvsp[-2].u.identifier)->get_scope(current_scope, global_scope);
- if (scope != nullptr) {
- scope->define_extension_type(et);
- }
- (yyval.u.decl) = et;
- }
-}
-#line 7117 "built/tmp/cppBison.yxx.c"
- break;
-
- case 328: /* type_decl: enum_keyword optional_attributes name */
-#line 2728 "dtool/src/cppparser/cppBison.yxx"
-{
- yywarning(string("C++ does not permit forward declaration of untyped enum ") + (yyvsp[0].u.identifier)->get_fully_scoped_name(), (yylsp[-2]));
-
- CPPType *type = (yyvsp[0].u.identifier)->find_type(current_scope, global_scope, false, current_lexer);
- if (type != nullptr) {
- (yyval.u.decl) = type;
- } else {
- CPPExtensionType *et =
- CPPType::new_type(new CPPExtensionType((yyvsp[-2].u.extension_enum), (yyvsp[0].u.identifier), current_scope, (yylsp[-2]).file, (yyvsp[-1].attr_list)))
- ->as_extension_type();
- CPPScope *scope = (yyvsp[0].u.identifier)->get_scope(current_scope, global_scope);
- if (scope != nullptr) {
- scope->define_extension_type(et);
- }
- (yyval.u.decl) = et;
- }
-}
-#line 7139 "built/tmp/cppBison.yxx.c"
- break;
-
- case 329: /* type_decl: KW_DECLTYPE '(' const_expr ')' */
-#line 2746 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.decl) = (yyvsp[-1].u.expr)->determine_type();
- if ((yyval.u.decl) == nullptr) {
- stringstream str;
- str << *(yyvsp[-1].u.expr);
- yyerror("could not determine type of " + str.str(), (yylsp[-1]));
- }
-}
-#line 7152 "built/tmp/cppBison.yxx.c"
- break;
-
- case 330: /* type_decl: KW_DECLTYPE '(' KW_AUTO ')' */
-#line 2755 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.decl) = CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_auto));
-}
-#line 7160 "built/tmp/cppBison.yxx.c"
- break;
-
- case 331: /* type_decl: KW_UNDERLYING_TYPE '(' full_type ')' */
-#line 2759 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPEnumType *enum_type = (yyvsp[-1].u.type)->as_enum_type();
- if (enum_type == nullptr) {
- yyerror("an enumeration type is required", (yylsp[-1]));
- (yyval.u.decl) = (yyvsp[-1].u.type);
- } else {
- (yyval.u.decl) = enum_type->get_underlying_type();
- }
-}
-#line 7174 "built/tmp/cppBison.yxx.c"
- break;
-
- case 332: /* type_decl: KW_AUTO */
-#line 2769 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.decl) = CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_auto));
-}
-#line 7182 "built/tmp/cppBison.yxx.c"
- break;
-
- case 333: /* type_decl: KW_BUILTIN_VA_LIST */
-#line 2773 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.decl) = CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_va_list));
-}
-#line 7190 "built/tmp/cppBison.yxx.c"
- break;
-
- case 334: /* predefined_type: simple_type */
-#line 2780 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.type) = CPPType::new_type((yyvsp[0].u.simple_type));
-}
-#line 7198 "built/tmp/cppBison.yxx.c"
- break;
-
- case 335: /* predefined_type: TYPENAME_IDENTIFIER */
-#line 2784 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.type) = (yyvsp[0].u.identifier)->find_type(current_scope, global_scope, false, current_lexer);
- if ((yyval.u.type) == nullptr) {
- yyerror(string("internal error resolving type ") + (yyvsp[0].u.identifier)->get_fully_scoped_name(), (yylsp[0]));
- }
- assert((yyval.u.type) != nullptr);
-}
-#line 7210 "built/tmp/cppBison.yxx.c"
- break;
-
- case 336: /* predefined_type: KW_TYPENAME name */
-#line 2792 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.type) = CPPType::new_type(new CPPTBDType((yyvsp[0].u.identifier)));
-}
-#line 7218 "built/tmp/cppBison.yxx.c"
- break;
-
- case 337: /* predefined_type: struct_keyword optional_attributes name */
-#line 2796 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPType *type = (yyvsp[0].u.identifier)->find_type(current_scope, global_scope, false, current_lexer);
- if (type != nullptr) {
- (yyval.u.type) = type;
- } else {
- CPPExtensionType *et =
- CPPType::new_type(new CPPExtensionType((yyvsp[-2].u.extension_enum), (yyvsp[0].u.identifier), current_scope, (yylsp[-2]).file, (yyvsp[-1].attr_list)))
- ->as_extension_type();
- CPPScope *scope = (yyvsp[0].u.identifier)->get_scope(current_scope, global_scope);
- if (scope != nullptr) {
- scope->define_extension_type(et);
- }
- (yyval.u.type) = et;
- }
-}
-#line 7238 "built/tmp/cppBison.yxx.c"
- break;
-
- case 338: /* predefined_type: enum_keyword optional_attributes name */
-#line 2812 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPType *type = (yyvsp[0].u.identifier)->find_type(current_scope, global_scope, false, current_lexer);
- if (type != nullptr) {
- (yyval.u.type) = type;
- } else {
- CPPExtensionType *et =
- CPPType::new_type(new CPPExtensionType((yyvsp[-2].u.extension_enum), (yyvsp[0].u.identifier), current_scope, (yylsp[-2]).file, (yyvsp[-1].attr_list)))
- ->as_extension_type();
- CPPScope *scope = (yyvsp[0].u.identifier)->get_scope(current_scope, global_scope);
- if (scope != nullptr) {
- scope->define_extension_type(et);
- }
- (yyval.u.type) = et;
- }
-}
-#line 7258 "built/tmp/cppBison.yxx.c"
- break;
-
- case 339: /* predefined_type: KW_DECLTYPE '(' const_expr ')' */
-#line 2828 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.type) = (yyvsp[-1].u.expr)->determine_type();
- if ((yyval.u.type) == nullptr) {
- stringstream str;
- str << *(yyvsp[-1].u.expr);
- yyerror("could not determine type of " + str.str(), (yylsp[-1]));
- }
-}
-#line 7271 "built/tmp/cppBison.yxx.c"
- break;
-
- case 340: /* predefined_type: KW_UNDERLYING_TYPE '(' full_type ')' */
-#line 2837 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPEnumType *enum_type = (yyvsp[-1].u.type)->as_enum_type();
- if (enum_type == nullptr) {
- yyerror("an enumeration type is required", (yylsp[-1]));
- (yyval.u.type) = (yyvsp[-1].u.type);
- } else {
- (yyval.u.type) = enum_type->get_underlying_type();
- }
-}
-#line 7285 "built/tmp/cppBison.yxx.c"
- break;
-
- case 341: /* predefined_type: KW_AUTO */
-#line 2847 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.type) = CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_auto));
-}
-#line 7293 "built/tmp/cppBison.yxx.c"
- break;
-
- case 342: /* predefined_type: KW_BUILTIN_VA_LIST */
-#line 2851 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.type) = CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_va_list));
-}
-#line 7301 "built/tmp/cppBison.yxx.c"
- break;
-
- case 343: /* var_type_decl: type_decl */
-#line 2858 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.decl) = (yyvsp[0].u.decl);
-}
-#line 7309 "built/tmp/cppBison.yxx.c"
- break;
-
- case 344: /* var_type_decl: IDENTIFIER */
-#line 2862 "dtool/src/cppparser/cppBison.yxx"
-{
- yyerror(string("unknown type '") + (yyvsp[0].u.identifier)->get_fully_scoped_name() + "'", (yylsp[0]));
-
- (yyval.u.decl) = CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_unknown));
-}
-#line 7319 "built/tmp/cppBison.yxx.c"
- break;
-
- case 345: /* full_type: type empty_instance_identifier */
-#line 2870 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.type) = (yyvsp[0].u.inst_ident)->unroll_type((yyvsp[-1].u.type));
-}
-#line 7327 "built/tmp/cppBison.yxx.c"
- break;
-
- case 346: /* full_type: KW_CONST type empty_instance_identifier */
-#line 2874 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyvsp[0].u.inst_ident)->add_modifier(IIT_const);
- (yyval.u.type) = (yyvsp[0].u.inst_ident)->unroll_type((yyvsp[-1].u.type));
-}
-#line 7336 "built/tmp/cppBison.yxx.c"
- break;
-
- case 347: /* full_type: type_pack empty_instance_identifier */
-#line 2879 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.type) = (yyvsp[0].u.inst_ident)->unroll_type((yyvsp[-1].u.type));
-}
-#line 7344 "built/tmp/cppBison.yxx.c"
- break;
-
- case 348: /* full_type: KW_CONST type_pack empty_instance_identifier */
-#line 2883 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyvsp[0].u.inst_ident)->add_modifier(IIT_const);
- (yyval.u.type) = (yyvsp[0].u.inst_ident)->unroll_type((yyvsp[-1].u.type));
-}
-#line 7353 "built/tmp/cppBison.yxx.c"
- break;
-
- case 349: /* $@17: %empty */
-#line 2891 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPVisibility starting_vis =
- ((yyvsp[-2].u.extension_enum) == CPPExtensionType::T_class) ? V_private : V_public;
-
- CPPScope *new_scope = new CPPScope(current_scope, CPPNameComponent("anon"),
- starting_vis);
- CPPStructType *st = new CPPStructType((yyvsp[-2].u.extension_enum), nullptr, current_scope,
- new_scope, (yylsp[-2]).file, (yyvsp[-1].attr_list));
- new_scope->set_struct_type(st);
-
- push_scope(new_scope);
- push_struct(st);
-}
-#line 7371 "built/tmp/cppBison.yxx.c"
- break;
-
- case 350: /* anonymous_struct: struct_keyword optional_attributes '{' $@17 cpp '}' */
-#line 2905 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.struct_type) = current_struct;
- current_struct->_incomplete = false;
- pop_struct();
- pop_scope();
-}
-#line 7382 "built/tmp/cppBison.yxx.c"
- break;
-
- case 351: /* $@18: %empty */
-#line 2915 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPVisibility starting_vis =
- ((yyvsp[-2].u.extension_enum) == CPPExtensionType::T_class) ? V_private : V_public;
-
- CPPScope *scope = (yyvsp[0].u.identifier)->get_scope(current_scope, global_scope, current_lexer);
- if (scope == nullptr) {
- scope = current_scope;
- }
- CPPScope *new_scope = new CPPScope(scope, (yyvsp[0].u.identifier)->_names.back(),
- starting_vis);
-
- CPPStructType *st = new CPPStructType((yyvsp[-2].u.extension_enum), (yyvsp[0].u.identifier), current_scope,
- new_scope, (yylsp[-2]).file, (yyvsp[-1].attr_list));
- new_scope->set_struct_type(st);
- current_scope->define_extension_type(st);
-
- push_scope(new_scope);
- push_struct(st);
-}
-#line 7406 "built/tmp/cppBison.yxx.c"
- break;
-
- case 352: /* named_struct: struct_keyword optional_attributes name_no_final $@18 maybe_final maybe_class_derivation '{' cpp '}' */
-#line 2935 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.struct_type) = current_struct;
- current_struct->_incomplete = false;
- pop_struct();
- pop_scope();
-}
-#line 7417 "built/tmp/cppBison.yxx.c"
- break;
-
- case 354: /* maybe_final: KW_FINAL */
-#line 2946 "dtool/src/cppparser/cppBison.yxx"
-{
- current_struct->_final = true;
-}
-#line 7425 "built/tmp/cppBison.yxx.c"
- break;
-
- case 359: /* base_specification: class_derivation_name */
-#line 2963 "dtool/src/cppparser/cppBison.yxx"
-{
- current_struct->append_derivation((yyvsp[0].u.type), V_unknown, false);
-}
-#line 7433 "built/tmp/cppBison.yxx.c"
- break;
-
- case 360: /* base_specification: KW_PUBLIC class_derivation_name */
-#line 2967 "dtool/src/cppparser/cppBison.yxx"
-{
- current_struct->append_derivation((yyvsp[0].u.type), V_public, false);
-}
-#line 7441 "built/tmp/cppBison.yxx.c"
- break;
-
- case 361: /* base_specification: KW_PROTECTED class_derivation_name */
-#line 2971 "dtool/src/cppparser/cppBison.yxx"
-{
- current_struct->append_derivation((yyvsp[0].u.type), V_protected, false);
-}
-#line 7449 "built/tmp/cppBison.yxx.c"
- break;
-
- case 362: /* base_specification: KW_PRIVATE class_derivation_name */
-#line 2975 "dtool/src/cppparser/cppBison.yxx"
-{
- current_struct->append_derivation((yyvsp[0].u.type), V_private, false);
-}
-#line 7457 "built/tmp/cppBison.yxx.c"
- break;
-
- case 363: /* base_specification: KW_VIRTUAL KW_PUBLIC class_derivation_name */
-#line 2979 "dtool/src/cppparser/cppBison.yxx"
-{
- current_struct->append_derivation((yyvsp[0].u.type), V_public, true);
-}
-#line 7465 "built/tmp/cppBison.yxx.c"
- break;
-
- case 364: /* base_specification: KW_VIRTUAL KW_PROTECTED class_derivation_name */
-#line 2983 "dtool/src/cppparser/cppBison.yxx"
-{
- current_struct->append_derivation((yyvsp[0].u.type), V_protected, true);
-}
-#line 7473 "built/tmp/cppBison.yxx.c"
- break;
-
- case 365: /* base_specification: KW_VIRTUAL KW_PRIVATE class_derivation_name */
-#line 2987 "dtool/src/cppparser/cppBison.yxx"
-{
- current_struct->append_derivation((yyvsp[0].u.type), V_private, true);
-}
-#line 7481 "built/tmp/cppBison.yxx.c"
- break;
-
- case 366: /* base_specification: KW_PUBLIC KW_VIRTUAL class_derivation_name */
-#line 2991 "dtool/src/cppparser/cppBison.yxx"
-{
- current_struct->append_derivation((yyvsp[0].u.type), V_public, true);
-}
-#line 7489 "built/tmp/cppBison.yxx.c"
- break;
-
- case 367: /* base_specification: KW_PROTECTED KW_VIRTUAL class_derivation_name */
-#line 2995 "dtool/src/cppparser/cppBison.yxx"
-{
- current_struct->append_derivation((yyvsp[0].u.type), V_protected, true);
-}
-#line 7497 "built/tmp/cppBison.yxx.c"
- break;
-
- case 368: /* base_specification: KW_PRIVATE KW_VIRTUAL class_derivation_name */
-#line 2999 "dtool/src/cppparser/cppBison.yxx"
-{
- current_struct->append_derivation((yyvsp[0].u.type), V_private, true);
-}
-#line 7505 "built/tmp/cppBison.yxx.c"
- break;
-
- case 369: /* $@19: %empty */
-#line 3006 "dtool/src/cppparser/cppBison.yxx"
-{
- if (current_enum->_scope != nullptr) {
- push_scope(current_enum->_scope);
- }
-}
-#line 7515 "built/tmp/cppBison.yxx.c"
- break;
-
- case 370: /* enum: enum_decl $@19 '{' enum_body '}' */
-#line 3012 "dtool/src/cppparser/cppBison.yxx"
-{
- if (current_enum->_scope != nullptr) {
- pop_scope();
- }
- (yyval.u.enum_type) = current_enum;
- current_enum = nullptr;
-}
-#line 7527 "built/tmp/cppBison.yxx.c"
- break;
-
- case 371: /* enum_decl: enum_keyword optional_attributes ':' enum_element_type */
-#line 3023 "dtool/src/cppparser/cppBison.yxx"
-{
- current_enum = new CPPEnumType((yyvsp[-3].u.extension_enum), nullptr, (yyvsp[0].u.type), current_scope, nullptr, (yylsp[-3]).file, (yyvsp[-2].attr_list));
-}
-#line 7535 "built/tmp/cppBison.yxx.c"
- break;
-
- case 372: /* enum_decl: enum_keyword optional_attributes */
-#line 3027 "dtool/src/cppparser/cppBison.yxx"
-{
- current_enum = new CPPEnumType((yyvsp[-1].u.extension_enum), nullptr, current_scope, nullptr, (yylsp[-1]).file, (yyvsp[0].attr_list));
-}
-#line 7543 "built/tmp/cppBison.yxx.c"
- break;
-
- case 373: /* enum_decl: enum_keyword optional_attributes name_no_final ':' enum_element_type */
-#line 3031 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPScope *new_scope = new CPPScope(current_scope, (yyvsp[-2].u.identifier)->_names.back(), V_public);
- current_enum = new CPPEnumType((yyvsp[-4].u.extension_enum), (yyvsp[-2].u.identifier), (yyvsp[0].u.type), current_scope, new_scope, (yylsp[-4]).file, (yyvsp[-3].attr_list));
-}
-#line 7552 "built/tmp/cppBison.yxx.c"
- break;
-
- case 374: /* enum_decl: enum_keyword optional_attributes name_no_final */
-#line 3036 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPScope *new_scope = new CPPScope(current_scope, (yyvsp[0].u.identifier)->_names.back(), V_public);
- current_enum = new CPPEnumType((yyvsp[-2].u.extension_enum), (yyvsp[0].u.identifier), current_scope, new_scope, (yylsp[-2]).file, (yyvsp[-1].attr_list));
-}
-#line 7561 "built/tmp/cppBison.yxx.c"
- break;
-
- case 375: /* enum_element_type: simple_int_type */
-#line 3044 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.type) = CPPType::new_type((yyvsp[0].u.simple_type));
-}
-#line 7569 "built/tmp/cppBison.yxx.c"
- break;
-
- case 376: /* enum_element_type: TYPENAME_IDENTIFIER */
-#line 3048 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.type) = (yyvsp[0].u.identifier)->find_type(current_scope, global_scope, false, current_lexer);
-}
-#line 7577 "built/tmp/cppBison.yxx.c"
- break;
-
- case 378: /* enum_body_trailing_comma: enum_body_trailing_comma name optional_attributes ',' */
-#line 3056 "dtool/src/cppparser/cppBison.yxx"
-{
- assert(current_enum != nullptr);
- current_enum->add_element((yyvsp[-2].u.identifier)->get_simple_name(), nullptr, current_lexer, (yylsp[-2]), (yyvsp[-1].attr_list));
-}
-#line 7586 "built/tmp/cppBison.yxx.c"
- break;
-
- case 379: /* enum_body_trailing_comma: enum_body_trailing_comma name optional_attributes '=' const_expr ',' */
-#line 3061 "dtool/src/cppparser/cppBison.yxx"
-{
- assert(current_enum != nullptr);
- current_enum->add_element((yyvsp[-4].u.identifier)->get_simple_name(), (yyvsp[-1].u.expr), current_lexer, (yylsp[-4]), (yyvsp[-3].attr_list));
-}
-#line 7595 "built/tmp/cppBison.yxx.c"
- break;
-
- case 381: /* enum_body: enum_body_trailing_comma name optional_attributes */
-#line 3069 "dtool/src/cppparser/cppBison.yxx"
-{
- assert(current_enum != nullptr);
- current_enum->add_element((yyvsp[-1].u.identifier)->get_simple_name(), nullptr, current_lexer, (yylsp[-1]), (yyvsp[0].attr_list));
-}
-#line 7604 "built/tmp/cppBison.yxx.c"
- break;
-
- case 382: /* enum_body: enum_body_trailing_comma name optional_attributes '=' const_expr */
-#line 3074 "dtool/src/cppparser/cppBison.yxx"
-{
- assert(current_enum != nullptr);
- current_enum->add_element((yyvsp[-3].u.identifier)->get_simple_name(), (yyvsp[0].u.expr), current_lexer, (yylsp[-3]), (yyvsp[-2].attr_list));
-}
-#line 7613 "built/tmp/cppBison.yxx.c"
- break;
-
- case 383: /* enum_keyword: KW_ENUM */
-#line 3082 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.extension_enum) = CPPExtensionType::T_enum;
-}
-#line 7621 "built/tmp/cppBison.yxx.c"
- break;
-
- case 384: /* enum_keyword: KW_ENUM KW_CLASS */
-#line 3086 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.extension_enum) = CPPExtensionType::T_enum_class;
-}
-#line 7629 "built/tmp/cppBison.yxx.c"
- break;
-
- case 385: /* enum_keyword: KW_ENUM KW_STRUCT */
-#line 3090 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.extension_enum) = CPPExtensionType::T_enum_struct;
-}
-#line 7637 "built/tmp/cppBison.yxx.c"
- break;
-
- case 386: /* struct_keyword: KW_CLASS */
-#line 3097 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.extension_enum) = CPPExtensionType::T_class;
-}
-#line 7645 "built/tmp/cppBison.yxx.c"
- break;
-
- case 387: /* struct_keyword: KW_STRUCT */
-#line 3101 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.extension_enum) = CPPExtensionType::T_struct;
-}
-#line 7653 "built/tmp/cppBison.yxx.c"
- break;
-
- case 388: /* struct_keyword: KW_UNION */
-#line 3105 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.extension_enum) = CPPExtensionType::T_union;
-}
-#line 7661 "built/tmp/cppBison.yxx.c"
- break;
-
- case 389: /* $@20: %empty */
-#line 3112 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPScope *scope = (yyvsp[-1].u.identifier)->find_scope(current_scope, global_scope, current_lexer);
- if (scope == nullptr) {
- // This must be a new namespace declaration.
- CPPScope *parent_scope =
- (yyvsp[-1].u.identifier)->get_scope(current_scope, global_scope, current_lexer);
- if (parent_scope == nullptr) {
- parent_scope = current_scope;
- }
- scope = new CPPScope(parent_scope, (yyvsp[-1].u.identifier)->_names.back(), V_public);
- }
-
- CPPNamespace *nspace = new CPPNamespace((yyvsp[-1].u.identifier), scope, (yylsp[-3]).file, (yyvsp[-2].attr_list));
- current_scope->add_declaration(nspace, global_scope, current_lexer, (yylsp[-3]));
- current_scope->define_namespace(nspace);
- push_scope(scope);
-}
-#line 7683 "built/tmp/cppBison.yxx.c"
- break;
-
- case 390: /* namespace_declaration: KW_NAMESPACE optional_attributes name '{' $@20 cpp '}' */
-#line 3130 "dtool/src/cppparser/cppBison.yxx"
-{
- pop_scope();
-}
-#line 7691 "built/tmp/cppBison.yxx.c"
- break;
-
- case 391: /* $@21: %empty */
-#line 3134 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPScope *scope = (yyvsp[-1].u.identifier)->find_scope(current_scope, global_scope, current_lexer);
- if (scope == nullptr) {
- // This must be a new namespace declaration.
- CPPScope *parent_scope =
- (yyvsp[-1].u.identifier)->get_scope(current_scope, global_scope, current_lexer);
- if (parent_scope == nullptr) {
- parent_scope = current_scope;
- }
- scope = new CPPScope(parent_scope, (yyvsp[-1].u.identifier)->_names.back(), V_public);
- }
-
- CPPNamespace *nspace = new CPPNamespace((yyvsp[-1].u.identifier), scope, (yylsp[-2]).file);
- nspace->_is_inline = true;
- current_scope->add_declaration(nspace, global_scope, current_lexer, (yylsp[-2]));
- current_scope->define_namespace(nspace);
- push_scope(scope);
-}
-#line 7714 "built/tmp/cppBison.yxx.c"
- break;
-
- case 392: /* namespace_declaration: KW_INLINE KW_NAMESPACE name '{' $@21 cpp '}' */
-#line 3153 "dtool/src/cppparser/cppBison.yxx"
-{
- pop_scope();
-}
-#line 7722 "built/tmp/cppBison.yxx.c"
- break;
-
- case 395: /* using_declaration: KW_USING name ';' */
-#line 3162 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPUsing *using_decl = new CPPUsing((yyvsp[-1].u.identifier), false, (yylsp[-2]).file);
- current_scope->add_declaration(using_decl, global_scope, current_lexer, (yylsp[-2]));
- current_scope->add_using(using_decl, global_scope, current_lexer);
-}
-#line 7732 "built/tmp/cppBison.yxx.c"
- break;
-
- case 396: /* using_declaration: KW_USING name optional_attributes '=' full_type ';' */
-#line 3168 "dtool/src/cppparser/cppBison.yxx"
-{
- // This is really just an alternative way to declare a typedef.
- CPPTypedefType *typedef_type = new CPPTypedefType((yyvsp[-1].u.type), (yyvsp[-4].u.identifier), current_scope, (yyvsp[-3].attr_list));
- typedef_type->_using = true;
- current_scope->add_declaration(CPPType::new_type(typedef_type), global_scope, current_lexer, (yylsp[-5]));
-}
-#line 7743 "built/tmp/cppBison.yxx.c"
- break;
-
- case 397: /* using_declaration: KW_USING KW_NAMESPACE name ';' */
-#line 3175 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPUsing *using_decl = new CPPUsing((yyvsp[-1].u.identifier), true, (yylsp[-3]).file);
- current_scope->add_declaration(using_decl, global_scope, current_lexer, (yylsp[-3]));
- current_scope->add_using(using_decl, global_scope, current_lexer);
-}
-#line 7753 "built/tmp/cppBison.yxx.c"
- break;
-
- case 398: /* using_declaration: KW_USING KW_ENUM name ';' */
-#line 3181 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPUsing *using_decl = new CPPUsing((yyvsp[-1].u.identifier), false, (yylsp[-3]).file);
- current_scope->add_declaration(using_decl, global_scope, current_lexer, (yylsp[-3]));
- current_scope->add_using(using_decl, global_scope, current_lexer);
-}
-#line 7763 "built/tmp/cppBison.yxx.c"
- break;
-
- case 402: /* simple_int_type: KW_BOOL */
-#line 3196 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.simple_type) = new CPPSimpleType(CPPSimpleType::T_bool);
-}
-#line 7771 "built/tmp/cppBison.yxx.c"
- break;
-
- case 403: /* simple_int_type: KW_CHAR */
-#line 3200 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.simple_type) = new CPPSimpleType(CPPSimpleType::T_char);
-}
-#line 7779 "built/tmp/cppBison.yxx.c"
- break;
-
- case 404: /* simple_int_type: KW_WCHAR_T */
-#line 3204 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.simple_type) = new CPPSimpleType(CPPSimpleType::T_wchar_t);
-}
-#line 7787 "built/tmp/cppBison.yxx.c"
- break;
-
- case 405: /* simple_int_type: KW_CHAR8_T */
-#line 3208 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.simple_type) = new CPPSimpleType(CPPSimpleType::T_char8_t);
-}
-#line 7795 "built/tmp/cppBison.yxx.c"
- break;
-
- case 406: /* simple_int_type: KW_CHAR16_T */
-#line 3212 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.simple_type) = new CPPSimpleType(CPPSimpleType::T_char16_t);
-}
-#line 7803 "built/tmp/cppBison.yxx.c"
- break;
-
- case 407: /* simple_int_type: KW_CHAR32_T */
-#line 3216 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.simple_type) = new CPPSimpleType(CPPSimpleType::T_char32_t);
-}
-#line 7811 "built/tmp/cppBison.yxx.c"
- break;
-
- case 408: /* simple_int_type: KW_SHORT */
-#line 3220 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.simple_type) = new CPPSimpleType(CPPSimpleType::T_int,
- CPPSimpleType::F_short);
-}
-#line 7820 "built/tmp/cppBison.yxx.c"
- break;
-
- case 409: /* simple_int_type: KW_LONG */
-#line 3225 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.simple_type) = new CPPSimpleType(CPPSimpleType::T_int,
- CPPSimpleType::F_long);
-}
-#line 7829 "built/tmp/cppBison.yxx.c"
- break;
-
- case 410: /* simple_int_type: KW_UNSIGNED */
-#line 3230 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.simple_type) = new CPPSimpleType(CPPSimpleType::T_int,
- CPPSimpleType::F_unsigned);
-}
-#line 7838 "built/tmp/cppBison.yxx.c"
- break;
-
- case 411: /* simple_int_type: KW_SIGNED */
-#line 3235 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.simple_type) = new CPPSimpleType(CPPSimpleType::T_int,
- CPPSimpleType::F_signed);
-}
-#line 7847 "built/tmp/cppBison.yxx.c"
- break;
-
- case 412: /* simple_int_type: KW_INT */
-#line 3240 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.simple_type) = new CPPSimpleType(CPPSimpleType::T_int);
-}
-#line 7855 "built/tmp/cppBison.yxx.c"
- break;
-
- case 413: /* simple_int_type: KW_SHORT simple_int_type */
-#line 3244 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.simple_type) = (yyvsp[0].u.simple_type);
- (yyval.u.simple_type)->_flags |= CPPSimpleType::F_short;
-}
-#line 7864 "built/tmp/cppBison.yxx.c"
- break;
-
- case 414: /* simple_int_type: KW_LONG simple_int_type */
-#line 3249 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.simple_type) = (yyvsp[0].u.simple_type);
- if ((yyval.u.simple_type)->_flags & CPPSimpleType::F_long) {
- (yyval.u.simple_type)->_flags |= CPPSimpleType::F_longlong;
- } else {
- (yyval.u.simple_type)->_flags |= CPPSimpleType::F_long;
- }
-}
-#line 7877 "built/tmp/cppBison.yxx.c"
- break;
-
- case 415: /* simple_int_type: KW_UNSIGNED simple_int_type */
-#line 3258 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.simple_type) = (yyvsp[0].u.simple_type);
- (yyval.u.simple_type)->_flags |= CPPSimpleType::F_unsigned;
-}
-#line 7886 "built/tmp/cppBison.yxx.c"
- break;
-
- case 416: /* simple_int_type: KW_SIGNED simple_int_type */
-#line 3263 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.simple_type) = (yyvsp[0].u.simple_type);
- (yyval.u.simple_type)->_flags |= CPPSimpleType::F_signed;
-}
-#line 7895 "built/tmp/cppBison.yxx.c"
- break;
-
- case 417: /* simple_float_type: KW_FLOAT */
-#line 3271 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.simple_type) = new CPPSimpleType(CPPSimpleType::T_float);
-}
-#line 7903 "built/tmp/cppBison.yxx.c"
- break;
-
- case 418: /* simple_float_type: KW_DOUBLE */
-#line 3275 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.simple_type) = new CPPSimpleType(CPPSimpleType::T_double);
-}
-#line 7911 "built/tmp/cppBison.yxx.c"
- break;
-
- case 419: /* simple_float_type: KW_LONG KW_DOUBLE */
-#line 3279 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.simple_type) = new CPPSimpleType(CPPSimpleType::T_double,
- CPPSimpleType::F_long);
-}
-#line 7920 "built/tmp/cppBison.yxx.c"
- break;
-
- case 420: /* simple_void_type: KW_VOID */
-#line 3287 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.simple_type) = new CPPSimpleType(CPPSimpleType::T_void);
-}
-#line 7928 "built/tmp/cppBison.yxx.c"
- break;
-
- case 421: /* $@22: %empty */
-#line 3296 "dtool/src/cppparser/cppBison.yxx"
-{
- current_lexer->_resolve_identifiers = false;
-}
-#line 7936 "built/tmp/cppBison.yxx.c"
- break;
-
- case 422: /* code: $@22 code_block */
-#line 3300 "dtool/src/cppparser/cppBison.yxx"
-{
- current_lexer->_resolve_identifiers = true;
-}
-#line 7944 "built/tmp/cppBison.yxx.c"
- break;
-
- case 539: /* element: KW_WHILE */
-#line 3345 "dtool/src/cppparser/cppBison.yxx"
-{
-}
-#line 7951 "built/tmp/cppBison.yxx.c"
- break;
-
- case 563: /* optional_const_expr: empty */
-#line 3354 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = nullptr;
-}
-#line 7959 "built/tmp/cppBison.yxx.c"
- break;
-
- case 564: /* optional_const_expr: const_expr */
-#line 3358 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = (yyvsp[0].u.expr);
-}
-#line 7967 "built/tmp/cppBison.yxx.c"
- break;
-
- case 565: /* optional_const_expr_comma: empty */
-#line 3365 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = nullptr;
-}
-#line 7975 "built/tmp/cppBison.yxx.c"
- break;
-
- case 566: /* optional_const_expr_comma: const_expr_comma */
-#line 3369 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = (yyvsp[0].u.expr);
-}
-#line 7983 "built/tmp/cppBison.yxx.c"
- break;
-
- case 567: /* const_expr_comma: const_expr */
-#line 3376 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = (yyvsp[0].u.expr);
-}
-#line 7991 "built/tmp/cppBison.yxx.c"
- break;
-
- case 568: /* const_expr_comma: const_expr_comma ',' const_expr */
-#line 3380 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(',', (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 7999 "built/tmp/cppBison.yxx.c"
- break;
-
- case 569: /* no_angle_bracket_const_expr: const_operand */
-#line 3387 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = (yyvsp[0].u.expr);
-}
-#line 8007 "built/tmp/cppBison.yxx.c"
- break;
-
- case 570: /* no_angle_bracket_const_expr: '(' full_type ')' no_angle_bracket_const_expr */
-#line 3391 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::typecast_op((yyvsp[-2].u.type), (yyvsp[0].u.expr)));
-}
-#line 8015 "built/tmp/cppBison.yxx.c"
- break;
-
- case 571: /* no_angle_bracket_const_expr: KW_STATIC_CAST '<' full_type '>' '(' const_expr_comma ')' */
-#line 3395 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::typecast_op((yyvsp[-4].u.type), (yyvsp[-1].u.expr), CPPExpression::T_static_cast));
-}
-#line 8023 "built/tmp/cppBison.yxx.c"
- break;
-
- case 572: /* no_angle_bracket_const_expr: KW_DYNAMIC_CAST '<' full_type '>' '(' const_expr_comma ')' */
-#line 3399 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::typecast_op((yyvsp[-4].u.type), (yyvsp[-1].u.expr), CPPExpression::T_dynamic_cast));
-}
-#line 8031 "built/tmp/cppBison.yxx.c"
- break;
-
- case 573: /* no_angle_bracket_const_expr: KW_CONST_CAST '<' full_type '>' '(' const_expr_comma ')' */
-#line 3403 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::typecast_op((yyvsp[-4].u.type), (yyvsp[-1].u.expr), CPPExpression::T_const_cast));
-}
-#line 8039 "built/tmp/cppBison.yxx.c"
- break;
-
- case 574: /* no_angle_bracket_const_expr: KW_REINTERPRET_CAST '<' full_type '>' '(' const_expr_comma ')' */
-#line 3407 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::typecast_op((yyvsp[-4].u.type), (yyvsp[-1].u.expr), CPPExpression::T_reinterpret_cast));
-}
-#line 8047 "built/tmp/cppBison.yxx.c"
- break;
-
- case 575: /* no_angle_bracket_const_expr: KW_SIZEOF '(' full_type ')' */
-#line 3411 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::sizeof_func((yyvsp[-1].u.type)));
-}
-#line 8055 "built/tmp/cppBison.yxx.c"
- break;
-
- case 576: /* no_angle_bracket_const_expr: KW_SIZEOF no_angle_bracket_const_expr */
-#line 3415 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::sizeof_func((yyvsp[0].u.expr)));
-}
-#line 8063 "built/tmp/cppBison.yxx.c"
- break;
-
- case 577: /* no_angle_bracket_const_expr: KW_SIZEOF ELLIPSIS '(' name ')' */
-#line 3419 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::sizeof_ellipsis_func((yyvsp[-1].u.identifier)));
-}
-#line 8071 "built/tmp/cppBison.yxx.c"
- break;
-
- case 578: /* no_angle_bracket_const_expr: KW_ALIGNOF '(' full_type ')' */
-#line 3423 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::alignof_func((yyvsp[-1].u.type)));
-}
-#line 8079 "built/tmp/cppBison.yxx.c"
- break;
-
- case 579: /* no_angle_bracket_const_expr: '!' no_angle_bracket_const_expr */
-#line 3427 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(UNARY_NOT, (yyvsp[0].u.expr));
-}
-#line 8087 "built/tmp/cppBison.yxx.c"
- break;
-
- case 580: /* no_angle_bracket_const_expr: '~' no_angle_bracket_const_expr */
-#line 3431 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(UNARY_NEGATE, (yyvsp[0].u.expr));
-}
-#line 8095 "built/tmp/cppBison.yxx.c"
- break;
-
- case 581: /* no_angle_bracket_const_expr: '-' no_angle_bracket_const_expr */
-#line 3435 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(UNARY_MINUS, (yyvsp[0].u.expr));
-}
-#line 8103 "built/tmp/cppBison.yxx.c"
- break;
-
- case 582: /* no_angle_bracket_const_expr: '+' no_angle_bracket_const_expr */
-#line 3439 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(UNARY_PLUS, (yyvsp[0].u.expr));
-}
-#line 8111 "built/tmp/cppBison.yxx.c"
- break;
-
- case 583: /* no_angle_bracket_const_expr: '*' no_angle_bracket_const_expr */
-#line 3443 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(UNARY_STAR, (yyvsp[0].u.expr));
-}
-#line 8119 "built/tmp/cppBison.yxx.c"
- break;
-
- case 584: /* no_angle_bracket_const_expr: '&' no_angle_bracket_const_expr */
-#line 3447 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(UNARY_REF, (yyvsp[0].u.expr));
-}
-#line 8127 "built/tmp/cppBison.yxx.c"
- break;
-
- case 585: /* no_angle_bracket_const_expr: no_angle_bracket_const_expr '*' no_angle_bracket_const_expr */
-#line 3451 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('*', (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 8135 "built/tmp/cppBison.yxx.c"
- break;
-
- case 586: /* no_angle_bracket_const_expr: no_angle_bracket_const_expr '/' no_angle_bracket_const_expr */
-#line 3455 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('/', (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 8143 "built/tmp/cppBison.yxx.c"
- break;
-
- case 587: /* no_angle_bracket_const_expr: no_angle_bracket_const_expr '%' no_angle_bracket_const_expr */
-#line 3459 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('%', (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 8151 "built/tmp/cppBison.yxx.c"
- break;
-
- case 588: /* no_angle_bracket_const_expr: no_angle_bracket_const_expr '+' no_angle_bracket_const_expr */
-#line 3463 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('+', (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 8159 "built/tmp/cppBison.yxx.c"
- break;
-
- case 589: /* no_angle_bracket_const_expr: no_angle_bracket_const_expr '-' no_angle_bracket_const_expr */
-#line 3467 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('-', (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 8167 "built/tmp/cppBison.yxx.c"
- break;
-
- case 590: /* no_angle_bracket_const_expr: no_angle_bracket_const_expr '|' no_angle_bracket_const_expr */
-#line 3471 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('|', (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 8175 "built/tmp/cppBison.yxx.c"
- break;
-
- case 591: /* no_angle_bracket_const_expr: no_angle_bracket_const_expr '^' no_angle_bracket_const_expr */
-#line 3475 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('^', (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 8183 "built/tmp/cppBison.yxx.c"
- break;
-
- case 592: /* no_angle_bracket_const_expr: no_angle_bracket_const_expr '&' no_angle_bracket_const_expr */
-#line 3479 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('&', (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 8191 "built/tmp/cppBison.yxx.c"
- break;
-
- case 593: /* no_angle_bracket_const_expr: no_angle_bracket_const_expr OROR no_angle_bracket_const_expr */
-#line 3483 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(OROR, (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 8199 "built/tmp/cppBison.yxx.c"
- break;
-
- case 594: /* no_angle_bracket_const_expr: no_angle_bracket_const_expr ANDAND no_angle_bracket_const_expr */
-#line 3487 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(ANDAND, (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 8207 "built/tmp/cppBison.yxx.c"
- break;
-
- case 595: /* no_angle_bracket_const_expr: no_angle_bracket_const_expr EQCOMPARE no_angle_bracket_const_expr */
-#line 3491 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(EQCOMPARE, (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 8215 "built/tmp/cppBison.yxx.c"
- break;
-
- case 596: /* no_angle_bracket_const_expr: no_angle_bracket_const_expr NECOMPARE no_angle_bracket_const_expr */
-#line 3495 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(NECOMPARE, (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 8223 "built/tmp/cppBison.yxx.c"
- break;
-
- case 597: /* no_angle_bracket_const_expr: no_angle_bracket_const_expr LECOMPARE no_angle_bracket_const_expr */
-#line 3499 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(LECOMPARE, (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 8231 "built/tmp/cppBison.yxx.c"
- break;
-
- case 598: /* no_angle_bracket_const_expr: no_angle_bracket_const_expr GECOMPARE no_angle_bracket_const_expr */
-#line 3503 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(GECOMPARE, (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 8239 "built/tmp/cppBison.yxx.c"
- break;
-
- case 599: /* no_angle_bracket_const_expr: no_angle_bracket_const_expr SPACESHIP no_angle_bracket_const_expr */
-#line 3507 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(SPACESHIP, (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 8247 "built/tmp/cppBison.yxx.c"
- break;
-
- case 600: /* no_angle_bracket_const_expr: no_angle_bracket_const_expr LSHIFT no_angle_bracket_const_expr */
-#line 3511 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(LSHIFT, (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 8255 "built/tmp/cppBison.yxx.c"
- break;
-
- case 601: /* no_angle_bracket_const_expr: no_angle_bracket_const_expr RSHIFT no_angle_bracket_const_expr */
-#line 3515 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(RSHIFT, (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 8263 "built/tmp/cppBison.yxx.c"
- break;
-
- case 602: /* no_angle_bracket_const_expr: no_angle_bracket_const_expr '?' no_angle_bracket_const_expr ':' no_angle_bracket_const_expr */
-#line 3519 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('?', (yyvsp[-4].u.expr), (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 8271 "built/tmp/cppBison.yxx.c"
- break;
-
- case 603: /* no_angle_bracket_const_expr: no_angle_bracket_const_expr '[' const_expr ']' */
-#line 3523 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('[', (yyvsp[-3].u.expr), (yyvsp[-1].u.expr));
-}
-#line 8279 "built/tmp/cppBison.yxx.c"
- break;
-
- case 604: /* no_angle_bracket_const_expr: no_angle_bracket_const_expr '(' const_expr_comma ')' */
-#line 3527 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('f', (yyvsp[-3].u.expr), (yyvsp[-1].u.expr));
-}
-#line 8287 "built/tmp/cppBison.yxx.c"
- break;
-
- case 605: /* no_angle_bracket_const_expr: no_angle_bracket_const_expr '(' ')' */
-#line 3531 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('f', (yyvsp[-2].u.expr));
-}
-#line 8295 "built/tmp/cppBison.yxx.c"
- break;
-
- case 606: /* no_angle_bracket_const_expr: no_angle_bracket_const_expr '.' name */
-#line 3535 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('.', (yyvsp[-2].u.expr), new CPPExpression((yyvsp[0].u.identifier), current_scope, global_scope, current_lexer));
-}
-#line 8303 "built/tmp/cppBison.yxx.c"
- break;
-
- case 607: /* no_angle_bracket_const_expr: no_angle_bracket_const_expr POINTSAT no_angle_bracket_const_expr */
-#line 3539 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(POINTSAT, (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 8311 "built/tmp/cppBison.yxx.c"
- break;
-
- case 608: /* no_angle_bracket_const_expr: '(' const_expr_comma ')' */
-#line 3543 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = (yyvsp[-1].u.expr);
-}
-#line 8319 "built/tmp/cppBison.yxx.c"
- break;
-
- case 609: /* const_expr: const_operand */
-#line 3551 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = (yyvsp[0].u.expr);
-}
-#line 8327 "built/tmp/cppBison.yxx.c"
- break;
-
- case 610: /* const_expr: '(' full_type ')' const_expr */
-#line 3555 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::typecast_op((yyvsp[-2].u.type), (yyvsp[0].u.expr)));
-}
-#line 8335 "built/tmp/cppBison.yxx.c"
- break;
-
- case 611: /* const_expr: KW_STATIC_CAST '<' full_type '>' '(' const_expr_comma ')' */
-#line 3559 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::typecast_op((yyvsp[-4].u.type), (yyvsp[-1].u.expr), CPPExpression::T_static_cast));
-}
-#line 8343 "built/tmp/cppBison.yxx.c"
- break;
-
- case 612: /* const_expr: KW_DYNAMIC_CAST '<' full_type '>' '(' const_expr_comma ')' */
-#line 3563 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::typecast_op((yyvsp[-4].u.type), (yyvsp[-1].u.expr), CPPExpression::T_dynamic_cast));
-}
-#line 8351 "built/tmp/cppBison.yxx.c"
- break;
-
- case 613: /* const_expr: KW_CONST_CAST '<' full_type '>' '(' const_expr_comma ')' */
-#line 3567 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::typecast_op((yyvsp[-4].u.type), (yyvsp[-1].u.expr), CPPExpression::T_const_cast));
-}
-#line 8359 "built/tmp/cppBison.yxx.c"
- break;
-
- case 614: /* const_expr: KW_REINTERPRET_CAST '<' full_type '>' '(' const_expr_comma ')' */
-#line 3571 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::typecast_op((yyvsp[-4].u.type), (yyvsp[-1].u.expr), CPPExpression::T_reinterpret_cast));
-}
-#line 8367 "built/tmp/cppBison.yxx.c"
- break;
-
- case 615: /* const_expr: TYPENAME_IDENTIFIER '(' optional_const_expr_comma ')' */
-#line 3575 "dtool/src/cppparser/cppBison.yxx"
-{
- // A constructor call.
- CPPType *type = (yyvsp[-3].u.identifier)->find_type(current_scope, global_scope, false, current_lexer);
- if (type == nullptr) {
- yyerror(string("internal error resolving type ") + (yyvsp[-3].u.identifier)->get_fully_scoped_name(), (yylsp[-3]));
- }
- assert(type != nullptr);
- (yyval.u.expr) = new CPPExpression(CPPExpression::construct_op(type, (yyvsp[-1].u.expr)));
-}
-#line 8381 "built/tmp/cppBison.yxx.c"
- break;
-
- case 616: /* const_expr: TYPENAME_IDENTIFIER '{' optional_const_expr_comma '}' */
-#line 3585 "dtool/src/cppparser/cppBison.yxx"
-{
- // Aggregate initialization.
- CPPType *type = (yyvsp[-3].u.identifier)->find_type(current_scope, global_scope, false, current_lexer);
- if (type == nullptr) {
- yyerror(string("internal error resolving type ") + (yyvsp[-3].u.identifier)->get_fully_scoped_name(), (yylsp[-3]));
- }
- assert(type != nullptr);
- (yyval.u.expr) = new CPPExpression(CPPExpression::aggregate_init_op(type, (yyvsp[-1].u.expr)));
-}
-#line 8395 "built/tmp/cppBison.yxx.c"
- break;
-
- case 617: /* const_expr: KW_INT '(' optional_const_expr_comma ')' */
-#line 3595 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPType *type =
- CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_int));
- (yyval.u.expr) = new CPPExpression(CPPExpression::construct_op(type, (yyvsp[-1].u.expr)));
-}
-#line 8405 "built/tmp/cppBison.yxx.c"
- break;
-
- case 618: /* const_expr: KW_CHAR '(' optional_const_expr_comma ')' */
-#line 3601 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPType *type =
- CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_char));
- (yyval.u.expr) = new CPPExpression(CPPExpression::construct_op(type, (yyvsp[-1].u.expr)));
-}
-#line 8415 "built/tmp/cppBison.yxx.c"
- break;
-
- case 619: /* const_expr: KW_WCHAR_T '(' optional_const_expr_comma ')' */
-#line 3607 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPType *type =
- CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_wchar_t));
- (yyval.u.expr) = new CPPExpression(CPPExpression::construct_op(type, (yyvsp[-1].u.expr)));
-}
-#line 8425 "built/tmp/cppBison.yxx.c"
- break;
-
- case 620: /* const_expr: KW_CHAR8_T '(' optional_const_expr_comma ')' */
-#line 3613 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPType *type =
- CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_char8_t));
- (yyval.u.expr) = new CPPExpression(CPPExpression::construct_op(type, (yyvsp[-1].u.expr)));
-}
-#line 8435 "built/tmp/cppBison.yxx.c"
- break;
-
- case 621: /* const_expr: KW_CHAR16_T '(' optional_const_expr_comma ')' */
-#line 3619 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPType *type =
- CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_char16_t));
- (yyval.u.expr) = new CPPExpression(CPPExpression::construct_op(type, (yyvsp[-1].u.expr)));
-}
-#line 8445 "built/tmp/cppBison.yxx.c"
- break;
-
- case 622: /* const_expr: KW_CHAR32_T '(' optional_const_expr_comma ')' */
-#line 3625 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPType *type =
- CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_char32_t));
- (yyval.u.expr) = new CPPExpression(CPPExpression::construct_op(type, (yyvsp[-1].u.expr)));
-}
-#line 8455 "built/tmp/cppBison.yxx.c"
- break;
-
- case 623: /* const_expr: KW_BOOL '(' optional_const_expr_comma ')' */
-#line 3631 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPType *type =
- CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_bool));
- (yyval.u.expr) = new CPPExpression(CPPExpression::construct_op(type, (yyvsp[-1].u.expr)));
-}
-#line 8465 "built/tmp/cppBison.yxx.c"
- break;
-
- case 624: /* const_expr: KW_SHORT '(' optional_const_expr_comma ')' */
-#line 3637 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPType *type =
- CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_int,
- CPPSimpleType::F_short));
- (yyval.u.expr) = new CPPExpression(CPPExpression::construct_op(type, (yyvsp[-1].u.expr)));
-}
-#line 8476 "built/tmp/cppBison.yxx.c"
- break;
-
- case 625: /* const_expr: KW_LONG '(' optional_const_expr_comma ')' */
-#line 3644 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPType *type =
- CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_int,
- CPPSimpleType::F_long));
- (yyval.u.expr) = new CPPExpression(CPPExpression::construct_op(type, (yyvsp[-1].u.expr)));
-}
-#line 8487 "built/tmp/cppBison.yxx.c"
- break;
-
- case 626: /* const_expr: KW_UNSIGNED '(' optional_const_expr_comma ')' */
-#line 3651 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPType *type =
- CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_int,
- CPPSimpleType::F_unsigned));
- (yyval.u.expr) = new CPPExpression(CPPExpression::construct_op(type, (yyvsp[-1].u.expr)));
-}
-#line 8498 "built/tmp/cppBison.yxx.c"
- break;
-
- case 627: /* const_expr: KW_SIGNED '(' optional_const_expr_comma ')' */
-#line 3658 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPType *type =
- CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_int,
- CPPSimpleType::F_signed));
- (yyval.u.expr) = new CPPExpression(CPPExpression::construct_op(type, (yyvsp[-1].u.expr)));
-}
-#line 8509 "built/tmp/cppBison.yxx.c"
- break;
-
- case 628: /* const_expr: KW_FLOAT '(' optional_const_expr_comma ')' */
-#line 3665 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPType *type =
- CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_float));
- (yyval.u.expr) = new CPPExpression(CPPExpression::construct_op(type, (yyvsp[-1].u.expr)));
-}
-#line 8519 "built/tmp/cppBison.yxx.c"
- break;
-
- case 629: /* const_expr: KW_DOUBLE '(' optional_const_expr_comma ')' */
-#line 3671 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPType *type =
- CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_double));
- (yyval.u.expr) = new CPPExpression(CPPExpression::construct_op(type, (yyvsp[-1].u.expr)));
-}
-#line 8529 "built/tmp/cppBison.yxx.c"
- break;
-
- case 630: /* const_expr: KW_SIZEOF '(' full_type ')' */
-#line 3677 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::sizeof_func((yyvsp[-1].u.type)));
-}
-#line 8537 "built/tmp/cppBison.yxx.c"
- break;
-
- case 631: /* const_expr: KW_SIZEOF const_expr */
-#line 3681 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::sizeof_func((yyvsp[0].u.expr)));
-}
-#line 8545 "built/tmp/cppBison.yxx.c"
- break;
-
- case 632: /* const_expr: KW_SIZEOF ELLIPSIS '(' name ')' */
-#line 3685 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::sizeof_ellipsis_func((yyvsp[-1].u.identifier)));
-}
-#line 8553 "built/tmp/cppBison.yxx.c"
- break;
-
- case 633: /* const_expr: KW_ALIGNOF '(' full_type ')' */
-#line 3689 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::alignof_func((yyvsp[-1].u.type)));
-}
-#line 8561 "built/tmp/cppBison.yxx.c"
- break;
-
- case 634: /* const_expr: KW_NEW predefined_type */
-#line 3693 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::new_op((yyvsp[0].u.type)));
-}
-#line 8569 "built/tmp/cppBison.yxx.c"
- break;
-
- case 635: /* const_expr: KW_NEW predefined_type '(' optional_const_expr_comma ')' */
-#line 3697 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::new_op((yyvsp[-3].u.type), (yyvsp[-1].u.expr)));
-}
-#line 8577 "built/tmp/cppBison.yxx.c"
- break;
-
- case 636: /* const_expr: KW_TYPEID '(' full_type ')' */
-#line 3701 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPIdentifier ident("");
- ident.add_name("std");
- ident.add_name("type_info");
- CPPType *std_type_info = ident.find_type(current_scope, global_scope, false, current_lexer);
- if (!std_type_info) {
- yywarning("cannot use typeid before including ", (yylsp[-3]));
- }
- (yyval.u.expr) = new CPPExpression(CPPExpression::typeid_op((yyvsp[-1].u.type), std_type_info));
-}
-#line 8592 "built/tmp/cppBison.yxx.c"
- break;
-
- case 637: /* const_expr: KW_TYPEID '(' const_expr ')' */
-#line 3712 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPIdentifier ident("");
- ident.add_name("std");
- ident.add_name("type_info");
- CPPType *std_type_info = ident.find_type(current_scope, global_scope, false, current_lexer);
- if (!std_type_info) {
- yywarning("cannot use typeid before including ", (yylsp[-3]));
- }
- (yyval.u.expr) = new CPPExpression(CPPExpression::typeid_op((yyvsp[-1].u.expr), std_type_info));
-}
-#line 8607 "built/tmp/cppBison.yxx.c"
- break;
-
- case 638: /* const_expr: '!' const_expr */
-#line 3723 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(UNARY_NOT, (yyvsp[0].u.expr));
-}
-#line 8615 "built/tmp/cppBison.yxx.c"
- break;
-
- case 639: /* const_expr: '~' const_expr */
-#line 3727 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(UNARY_NEGATE, (yyvsp[0].u.expr));
-}
-#line 8623 "built/tmp/cppBison.yxx.c"
- break;
-
- case 640: /* const_expr: '-' const_expr */
-#line 3731 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(UNARY_MINUS, (yyvsp[0].u.expr));
-}
-#line 8631 "built/tmp/cppBison.yxx.c"
- break;
-
- case 641: /* const_expr: '+' const_expr */
-#line 3735 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(UNARY_PLUS, (yyvsp[0].u.expr));
-}
-#line 8639 "built/tmp/cppBison.yxx.c"
- break;
-
- case 642: /* const_expr: '*' const_expr */
-#line 3739 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(UNARY_STAR, (yyvsp[0].u.expr));
-}
-#line 8647 "built/tmp/cppBison.yxx.c"
- break;
-
- case 643: /* const_expr: '&' const_expr */
-#line 3743 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(UNARY_REF, (yyvsp[0].u.expr));
-}
-#line 8655 "built/tmp/cppBison.yxx.c"
- break;
-
- case 644: /* const_expr: const_expr '*' const_expr */
-#line 3747 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('*', (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 8663 "built/tmp/cppBison.yxx.c"
- break;
-
- case 645: /* const_expr: const_expr '/' const_expr */
-#line 3751 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('/', (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 8671 "built/tmp/cppBison.yxx.c"
- break;
-
- case 646: /* const_expr: const_expr '%' const_expr */
-#line 3755 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('%', (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 8679 "built/tmp/cppBison.yxx.c"
- break;
-
- case 647: /* const_expr: const_expr '+' const_expr */
-#line 3759 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('+', (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 8687 "built/tmp/cppBison.yxx.c"
- break;
-
- case 648: /* const_expr: const_expr '-' const_expr */
-#line 3763 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('-', (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 8695 "built/tmp/cppBison.yxx.c"
- break;
-
- case 649: /* const_expr: const_expr '|' const_expr */
-#line 3767 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('|', (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 8703 "built/tmp/cppBison.yxx.c"
- break;
-
- case 650: /* const_expr: const_expr '^' const_expr */
-#line 3771 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('^', (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 8711 "built/tmp/cppBison.yxx.c"
- break;
-
- case 651: /* const_expr: const_expr '&' const_expr */
-#line 3775 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('&', (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 8719 "built/tmp/cppBison.yxx.c"
- break;
-
- case 652: /* const_expr: const_expr OROR const_expr */
-#line 3779 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(OROR, (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 8727 "built/tmp/cppBison.yxx.c"
- break;
-
- case 653: /* const_expr: const_expr ANDAND const_expr */
-#line 3783 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(ANDAND, (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 8735 "built/tmp/cppBison.yxx.c"
- break;
-
- case 654: /* const_expr: const_expr EQCOMPARE const_expr */
-#line 3787 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(EQCOMPARE, (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 8743 "built/tmp/cppBison.yxx.c"
- break;
-
- case 655: /* const_expr: const_expr NECOMPARE const_expr */
-#line 3791 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(NECOMPARE, (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 8751 "built/tmp/cppBison.yxx.c"
- break;
-
- case 656: /* const_expr: const_expr LECOMPARE const_expr */
-#line 3795 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(LECOMPARE, (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 8759 "built/tmp/cppBison.yxx.c"
- break;
-
- case 657: /* const_expr: const_expr GECOMPARE const_expr */
-#line 3799 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(GECOMPARE, (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 8767 "built/tmp/cppBison.yxx.c"
- break;
-
- case 658: /* const_expr: const_expr SPACESHIP const_expr */
-#line 3803 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(SPACESHIP, (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 8775 "built/tmp/cppBison.yxx.c"
- break;
-
- case 659: /* const_expr: const_expr '<' const_expr */
-#line 3807 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('<', (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 8783 "built/tmp/cppBison.yxx.c"
- break;
-
- case 660: /* const_expr: const_expr '>' const_expr */
-#line 3811 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('>', (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 8791 "built/tmp/cppBison.yxx.c"
- break;
-
- case 661: /* const_expr: const_expr LSHIFT const_expr */
-#line 3815 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(LSHIFT, (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 8799 "built/tmp/cppBison.yxx.c"
- break;
-
- case 662: /* const_expr: const_expr RSHIFT const_expr */
-#line 3819 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(RSHIFT, (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 8807 "built/tmp/cppBison.yxx.c"
- break;
-
- case 663: /* const_expr: const_expr '?' const_expr ':' const_expr */
-#line 3823 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('?', (yyvsp[-4].u.expr), (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 8815 "built/tmp/cppBison.yxx.c"
- break;
-
- case 664: /* const_expr: const_expr '[' const_expr ']' */
-#line 3827 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('[', (yyvsp[-3].u.expr), (yyvsp[-1].u.expr));
-}
-#line 8823 "built/tmp/cppBison.yxx.c"
- break;
-
- case 665: /* const_expr: const_expr '(' const_expr_comma ')' */
-#line 3831 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('f', (yyvsp[-3].u.expr), (yyvsp[-1].u.expr));
-}
-#line 8831 "built/tmp/cppBison.yxx.c"
- break;
-
- case 666: /* const_expr: const_expr '(' ')' */
-#line 3835 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('f', (yyvsp[-2].u.expr));
-}
-#line 8839 "built/tmp/cppBison.yxx.c"
- break;
-
- case 667: /* const_expr: KW_NOEXCEPT_LPAREN const_expr ')' */
-#line 3839 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(KW_NOEXCEPT, (yyvsp[-1].u.expr));
-}
-#line 8847 "built/tmp/cppBison.yxx.c"
- break;
-
- case 668: /* const_expr: const_expr '.' name */
-#line 3843 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('.', (yyvsp[-2].u.expr), new CPPExpression((yyvsp[0].u.identifier), current_scope, global_scope, current_lexer));
-}
-#line 8855 "built/tmp/cppBison.yxx.c"
- break;
-
- case 669: /* const_expr: const_expr POINTSAT const_expr */
-#line 3847 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(POINTSAT, (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 8863 "built/tmp/cppBison.yxx.c"
- break;
-
- case 670: /* const_expr: '(' const_expr_comma ')' */
-#line 3851 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = (yyvsp[-1].u.expr);
-}
-#line 8871 "built/tmp/cppBison.yxx.c"
- break;
-
- case 671: /* const_operand: INTEGER */
-#line 3858 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression((yyvsp[0].u.integer));
-}
-#line 8879 "built/tmp/cppBison.yxx.c"
- break;
-
- case 672: /* const_operand: KW_TRUE */
-#line 3862 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(true);
-}
-#line 8887 "built/tmp/cppBison.yxx.c"
- break;
-
- case 673: /* const_operand: KW_FALSE */
-#line 3866 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(false);
-}
-#line 8895 "built/tmp/cppBison.yxx.c"
- break;
-
- case 674: /* const_operand: CHAR_TOK */
-#line 3870 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression((yyvsp[0].u.integer));
-}
-#line 8903 "built/tmp/cppBison.yxx.c"
- break;
-
- case 675: /* const_operand: REAL */
-#line 3874 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression((yyvsp[0].u.real));
-}
-#line 8911 "built/tmp/cppBison.yxx.c"
- break;
-
- case 676: /* const_operand: string_literal */
-#line 3878 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = (yyvsp[0].u.expr);
-}
-#line 8919 "built/tmp/cppBison.yxx.c"
- break;
-
- case 677: /* const_operand: CUSTOM_LITERAL */
-#line 3882 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = (yyvsp[0].u.expr);
-}
-#line 8927 "built/tmp/cppBison.yxx.c"
- break;
-
- case 678: /* const_operand: IDENTIFIER */
-#line 3886 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression((yyvsp[0].u.identifier), current_scope, global_scope, current_lexer);
-}
-#line 8935 "built/tmp/cppBison.yxx.c"
- break;
-
- case 679: /* const_operand: KW_FINAL */
-#line 3890 "dtool/src/cppparser/cppBison.yxx"
-{
- // A variable named "final". C++11 explicitly permits this.
- CPPIdentifier *ident = new CPPIdentifier("final", (yylsp[0]));
- (yyval.u.expr) = new CPPExpression(ident, current_scope, global_scope, current_lexer);
-}
-#line 8945 "built/tmp/cppBison.yxx.c"
- break;
-
- case 680: /* const_operand: KW_OVERRIDE */
-#line 3896 "dtool/src/cppparser/cppBison.yxx"
-{
- // A variable named "override". C++11 explicitly permits this.
- CPPIdentifier *ident = new CPPIdentifier("override", (yylsp[0]));
- (yyval.u.expr) = new CPPExpression(ident, current_scope, global_scope, current_lexer);
-}
-#line 8955 "built/tmp/cppBison.yxx.c"
- break;
-
- case 681: /* const_operand: KW_NULLPTR */
-#line 3902 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::get_nullptr());
-}
-#line 8963 "built/tmp/cppBison.yxx.c"
- break;
-
- case 682: /* const_operand: '[' capture_list ']' function_post optional_attributes maybe_trailing_return_type '{' code '}' */
-#line 3906 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyvsp[-7].u.closure_type)->_flags = (yyvsp[-5].u.integer);
- (yyvsp[-7].u.closure_type)->_attributes = (yyvsp[-4].attr_list);
- (yyvsp[-7].u.closure_type)->_return_type = (yyvsp[-3].u.type);
- (yyval.u.expr) = new CPPExpression(CPPExpression::lambda((yyvsp[-7].u.closure_type)));
-}
-#line 8974 "built/tmp/cppBison.yxx.c"
- break;
-
- case 683: /* const_operand: '[' capture_list ']' '(' function_parameter_list ')' function_post optional_attributes maybe_trailing_return_type '{' code '}' */
-#line 3913 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyvsp[-10].u.closure_type)->_parameters = (yyvsp[-7].u.param_list);
- (yyvsp[-10].u.closure_type)->_flags = (yyvsp[-5].u.integer);
- (yyvsp[-10].u.closure_type)->_attributes = (yyvsp[-4].attr_list);
- (yyvsp[-10].u.closure_type)->_return_type = (yyvsp[-3].u.type);
- (yyval.u.expr) = new CPPExpression(CPPExpression::lambda((yyvsp[-10].u.closure_type)));
-}
-#line 8986 "built/tmp/cppBison.yxx.c"
- break;
-
- case 684: /* const_operand: KW_HAS_VIRTUAL_DESTRUCTOR '(' full_type ')' */
-#line 3921 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::type_trait(KW_HAS_VIRTUAL_DESTRUCTOR, (yyvsp[-1].u.type)));
-}
-#line 8994 "built/tmp/cppBison.yxx.c"
- break;
-
- case 685: /* const_operand: KW_IS_ABSTRACT '(' full_type ')' */
-#line 3925 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::type_trait(KW_IS_ABSTRACT, (yyvsp[-1].u.type)));
-}
-#line 9002 "built/tmp/cppBison.yxx.c"
- break;
-
- case 686: /* const_operand: KW_IS_BASE_OF '(' full_type ',' full_type ')' */
-#line 3929 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::type_trait(KW_IS_CLASS, (yyvsp[-3].u.type), (yyvsp[-1].u.type)));
-}
-#line 9010 "built/tmp/cppBison.yxx.c"
- break;
-
- case 687: /* const_operand: KW_IS_CLASS '(' full_type ')' */
-#line 3933 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::type_trait(KW_IS_CLASS, (yyvsp[-1].u.type)));
-}
-#line 9018 "built/tmp/cppBison.yxx.c"
- break;
-
- case 688: /* const_operand: KW_IS_CONSTRUCTIBLE '(' full_type ')' */
-#line 3937 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::type_trait(KW_IS_CONSTRUCTIBLE, (yyvsp[-1].u.type)));
-}
-#line 9026 "built/tmp/cppBison.yxx.c"
- break;
-
- case 689: /* const_operand: KW_IS_CONSTRUCTIBLE '(' full_type ',' full_type ')' */
-#line 3941 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::type_trait(KW_IS_CONSTRUCTIBLE, (yyvsp[-3].u.type), (yyvsp[-1].u.type)));
-}
-#line 9034 "built/tmp/cppBison.yxx.c"
- break;
-
- case 690: /* const_operand: KW_IS_CONVERTIBLE_TO '(' full_type ',' full_type ')' */
-#line 3945 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::type_trait(KW_IS_CONVERTIBLE_TO, (yyvsp[-3].u.type), (yyvsp[-1].u.type)));
-}
-#line 9042 "built/tmp/cppBison.yxx.c"
- break;
-
- case 691: /* const_operand: KW_IS_DESTRUCTIBLE '(' full_type ')' */
-#line 3949 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::type_trait(KW_IS_DESTRUCTIBLE, (yyvsp[-1].u.type)));
-}
-#line 9050 "built/tmp/cppBison.yxx.c"
- break;
-
- case 692: /* const_operand: KW_IS_EMPTY '(' full_type ')' */
-#line 3953 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::type_trait(KW_IS_EMPTY, (yyvsp[-1].u.type)));
-}
-#line 9058 "built/tmp/cppBison.yxx.c"
- break;
-
- case 693: /* const_operand: KW_IS_ENUM '(' full_type ')' */
-#line 3957 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::type_trait(KW_IS_ENUM, (yyvsp[-1].u.type)));
-}
-#line 9066 "built/tmp/cppBison.yxx.c"
- break;
-
- case 694: /* const_operand: KW_IS_FINAL '(' full_type ')' */
-#line 3961 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::type_trait(KW_IS_FINAL, (yyvsp[-1].u.type)));
-}
-#line 9074 "built/tmp/cppBison.yxx.c"
- break;
-
- case 695: /* const_operand: KW_IS_FUNDAMENTAL '(' full_type ')' */
-#line 3965 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::type_trait(KW_IS_FUNDAMENTAL, (yyvsp[-1].u.type)));
-}
-#line 9082 "built/tmp/cppBison.yxx.c"
- break;
-
- case 696: /* const_operand: KW_IS_POD '(' full_type ')' */
-#line 3969 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::type_trait(KW_IS_POD, (yyvsp[-1].u.type)));
-}
-#line 9090 "built/tmp/cppBison.yxx.c"
- break;
-
- case 697: /* const_operand: KW_IS_POLYMORPHIC '(' full_type ')' */
-#line 3973 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::type_trait(KW_IS_POLYMORPHIC, (yyvsp[-1].u.type)));
-}
-#line 9098 "built/tmp/cppBison.yxx.c"
- break;
-
- case 698: /* const_operand: KW_IS_STANDARD_LAYOUT '(' full_type ')' */
-#line 3977 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::type_trait(KW_IS_STANDARD_LAYOUT, (yyvsp[-1].u.type)));
-}
-#line 9106 "built/tmp/cppBison.yxx.c"
- break;
-
- case 699: /* const_operand: KW_IS_TRIVIAL '(' full_type ')' */
-#line 3981 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::type_trait(KW_IS_TRIVIAL, (yyvsp[-1].u.type)));
-}
-#line 9114 "built/tmp/cppBison.yxx.c"
- break;
-
- case 700: /* const_operand: KW_IS_TRIVIALLY_COPYABLE '(' full_type ')' */
-#line 3985 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::type_trait(KW_IS_TRIVIALLY_COPYABLE, (yyvsp[-1].u.type)));
-}
-#line 9122 "built/tmp/cppBison.yxx.c"
- break;
-
- case 701: /* const_operand: KW_IS_UNION '(' full_type ')' */
-#line 3989 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::type_trait(KW_IS_UNION, (yyvsp[-1].u.type)));
-}
-#line 9130 "built/tmp/cppBison.yxx.c"
- break;
-
- case 702: /* formal_const_expr: formal_const_operand */
-#line 4003 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = (yyvsp[0].u.expr);
-}
-#line 9138 "built/tmp/cppBison.yxx.c"
- break;
-
- case 703: /* formal_const_expr: '(' full_type ')' const_expr */
-#line 4007 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::typecast_op((yyvsp[-2].u.type), (yyvsp[0].u.expr)));
-}
-#line 9146 "built/tmp/cppBison.yxx.c"
- break;
-
- case 704: /* formal_const_expr: KW_STATIC_CAST '<' full_type '>' '(' const_expr_comma ')' */
-#line 4011 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::typecast_op((yyvsp[-4].u.type), (yyvsp[-1].u.expr), CPPExpression::T_static_cast));
-}
-#line 9154 "built/tmp/cppBison.yxx.c"
- break;
-
- case 705: /* formal_const_expr: KW_DYNAMIC_CAST '<' full_type '>' '(' const_expr_comma ')' */
-#line 4015 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::typecast_op((yyvsp[-4].u.type), (yyvsp[-1].u.expr), CPPExpression::T_dynamic_cast));
-}
-#line 9162 "built/tmp/cppBison.yxx.c"
- break;
-
- case 706: /* formal_const_expr: KW_CONST_CAST '<' full_type '>' '(' const_expr_comma ')' */
-#line 4019 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::typecast_op((yyvsp[-4].u.type), (yyvsp[-1].u.expr), CPPExpression::T_const_cast));
-}
-#line 9170 "built/tmp/cppBison.yxx.c"
- break;
-
- case 707: /* formal_const_expr: KW_REINTERPRET_CAST '<' full_type '>' '(' const_expr_comma ')' */
-#line 4023 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::typecast_op((yyvsp[-4].u.type), (yyvsp[-1].u.expr), CPPExpression::T_reinterpret_cast));
-}
-#line 9178 "built/tmp/cppBison.yxx.c"
- break;
-
- case 708: /* formal_const_expr: KW_SIZEOF '(' full_type ')' */
-#line 4027 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::sizeof_func((yyvsp[-1].u.type)));
-}
-#line 9186 "built/tmp/cppBison.yxx.c"
- break;
-
- case 709: /* formal_const_expr: KW_SIZEOF formal_const_expr */
-#line 4031 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::sizeof_func((yyvsp[0].u.expr)));
-}
-#line 9194 "built/tmp/cppBison.yxx.c"
- break;
-
- case 710: /* formal_const_expr: KW_SIZEOF ELLIPSIS '(' name ')' */
-#line 4035 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::sizeof_ellipsis_func((yyvsp[-1].u.identifier)));
-}
-#line 9202 "built/tmp/cppBison.yxx.c"
- break;
-
- case 711: /* formal_const_expr: KW_ALIGNOF '(' full_type ')' */
-#line 4039 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::alignof_func((yyvsp[-1].u.type)));
-}
-#line 9210 "built/tmp/cppBison.yxx.c"
- break;
-
- case 712: /* formal_const_expr: KW_NEW predefined_type */
-#line 4043 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::new_op((yyvsp[0].u.type)));
-}
-#line 9218 "built/tmp/cppBison.yxx.c"
- break;
-
- case 713: /* formal_const_expr: KW_NEW predefined_type '(' optional_const_expr_comma ')' */
-#line 4047 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::new_op((yyvsp[-3].u.type), (yyvsp[-1].u.expr)));
-}
-#line 9226 "built/tmp/cppBison.yxx.c"
- break;
-
- case 714: /* formal_const_expr: KW_TYPEID '(' full_type ')' */
-#line 4051 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPIdentifier ident("");
- ident.add_name("std");
- ident.add_name("type_info");
- CPPType *std_type_info = ident.find_type(current_scope, global_scope, false, current_lexer);
- if (!std_type_info) {
- yywarning("cannot use typeid before including ", (yylsp[-3]));
- }
- (yyval.u.expr) = new CPPExpression(CPPExpression::typeid_op((yyvsp[-1].u.type), std_type_info));
-}
-#line 9241 "built/tmp/cppBison.yxx.c"
- break;
-
- case 715: /* formal_const_expr: KW_TYPEID '(' const_expr ')' */
-#line 4062 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPIdentifier ident("");
- ident.add_name("std");
- ident.add_name("type_info");
- CPPType *std_type_info = ident.find_type(current_scope, global_scope, false, current_lexer);
- if (!std_type_info) {
- yywarning("cannot use typeid before including ", (yylsp[-3]));
- }
- (yyval.u.expr) = new CPPExpression(CPPExpression::typeid_op((yyvsp[-1].u.expr), std_type_info));
-}
-#line 9256 "built/tmp/cppBison.yxx.c"
- break;
-
- case 716: /* formal_const_expr: '!' const_expr */
-#line 4073 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(UNARY_NOT, (yyvsp[0].u.expr));
-}
-#line 9264 "built/tmp/cppBison.yxx.c"
- break;
-
- case 717: /* formal_const_expr: '~' const_expr */
-#line 4077 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(UNARY_NEGATE, (yyvsp[0].u.expr));
-}
-#line 9272 "built/tmp/cppBison.yxx.c"
- break;
-
- case 718: /* formal_const_expr: '-' const_expr */
-#line 4081 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(UNARY_MINUS, (yyvsp[0].u.expr));
-}
-#line 9280 "built/tmp/cppBison.yxx.c"
- break;
-
- case 719: /* formal_const_expr: '+' const_expr */
-#line 4085 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(UNARY_PLUS, (yyvsp[0].u.expr));
-}
-#line 9288 "built/tmp/cppBison.yxx.c"
- break;
-
- case 720: /* formal_const_expr: '&' const_expr */
-#line 4089 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(UNARY_REF, (yyvsp[0].u.expr));
-}
-#line 9296 "built/tmp/cppBison.yxx.c"
- break;
-
- case 721: /* formal_const_expr: formal_const_expr '*' const_expr */
-#line 4093 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('*', (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 9304 "built/tmp/cppBison.yxx.c"
- break;
-
- case 722: /* formal_const_expr: formal_const_expr '/' const_expr */
-#line 4097 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('/', (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 9312 "built/tmp/cppBison.yxx.c"
- break;
-
- case 723: /* formal_const_expr: formal_const_expr '%' const_expr */
-#line 4101 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('%', (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 9320 "built/tmp/cppBison.yxx.c"
- break;
-
- case 724: /* formal_const_expr: formal_const_expr '+' const_expr */
-#line 4105 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('+', (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 9328 "built/tmp/cppBison.yxx.c"
- break;
-
- case 725: /* formal_const_expr: formal_const_expr '-' const_expr */
-#line 4109 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('-', (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 9336 "built/tmp/cppBison.yxx.c"
- break;
-
- case 726: /* formal_const_expr: formal_const_expr '|' const_expr */
-#line 4113 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('|', (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 9344 "built/tmp/cppBison.yxx.c"
- break;
-
- case 727: /* formal_const_expr: formal_const_expr '^' const_expr */
-#line 4117 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('^', (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 9352 "built/tmp/cppBison.yxx.c"
- break;
-
- case 728: /* formal_const_expr: formal_const_expr '&' const_expr */
-#line 4121 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('&', (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 9360 "built/tmp/cppBison.yxx.c"
- break;
-
- case 729: /* formal_const_expr: formal_const_expr OROR const_expr */
-#line 4125 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(OROR, (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 9368 "built/tmp/cppBison.yxx.c"
- break;
-
- case 730: /* formal_const_expr: formal_const_expr ANDAND const_expr */
-#line 4129 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(ANDAND, (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 9376 "built/tmp/cppBison.yxx.c"
- break;
-
- case 731: /* formal_const_expr: formal_const_expr EQCOMPARE const_expr */
-#line 4133 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(EQCOMPARE, (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 9384 "built/tmp/cppBison.yxx.c"
- break;
-
- case 732: /* formal_const_expr: formal_const_expr NECOMPARE const_expr */
-#line 4137 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(NECOMPARE, (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 9392 "built/tmp/cppBison.yxx.c"
- break;
-
- case 733: /* formal_const_expr: formal_const_expr LECOMPARE const_expr */
-#line 4141 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(LECOMPARE, (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 9400 "built/tmp/cppBison.yxx.c"
- break;
-
- case 734: /* formal_const_expr: formal_const_expr GECOMPARE const_expr */
-#line 4145 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(GECOMPARE, (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 9408 "built/tmp/cppBison.yxx.c"
- break;
-
- case 735: /* formal_const_expr: formal_const_expr SPACESHIP const_expr */
-#line 4149 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(SPACESHIP, (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 9416 "built/tmp/cppBison.yxx.c"
- break;
-
- case 736: /* formal_const_expr: formal_const_expr '<' const_expr */
-#line 4153 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('<', (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 9424 "built/tmp/cppBison.yxx.c"
- break;
-
- case 737: /* formal_const_expr: formal_const_expr '>' const_expr */
-#line 4157 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('>', (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 9432 "built/tmp/cppBison.yxx.c"
- break;
-
- case 738: /* formal_const_expr: formal_const_expr LSHIFT const_expr */
-#line 4161 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(LSHIFT, (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 9440 "built/tmp/cppBison.yxx.c"
- break;
-
- case 739: /* formal_const_expr: formal_const_expr RSHIFT const_expr */
-#line 4165 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(RSHIFT, (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 9448 "built/tmp/cppBison.yxx.c"
- break;
-
- case 740: /* formal_const_expr: formal_const_expr '?' const_expr ':' const_expr */
-#line 4169 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('?', (yyvsp[-4].u.expr), (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 9456 "built/tmp/cppBison.yxx.c"
- break;
-
- case 741: /* formal_const_expr: formal_const_expr '[' const_expr ']' */
-#line 4173 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('[', (yyvsp[-3].u.expr), (yyvsp[-1].u.expr));
-}
-#line 9464 "built/tmp/cppBison.yxx.c"
- break;
-
- case 742: /* formal_const_expr: formal_const_expr '(' const_expr_comma ')' */
-#line 4177 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('f', (yyvsp[-3].u.expr), (yyvsp[-1].u.expr));
-}
-#line 9472 "built/tmp/cppBison.yxx.c"
- break;
-
- case 743: /* formal_const_expr: formal_const_expr '(' ')' */
-#line 4181 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('f', (yyvsp[-2].u.expr));
-}
-#line 9480 "built/tmp/cppBison.yxx.c"
- break;
-
- case 744: /* formal_const_expr: formal_const_expr '.' name */
-#line 4185 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression('.', (yyvsp[-2].u.expr), new CPPExpression((yyvsp[0].u.identifier), current_scope, global_scope, current_lexer));
-}
-#line 9488 "built/tmp/cppBison.yxx.c"
- break;
-
- case 745: /* formal_const_expr: formal_const_expr POINTSAT const_expr */
-#line 4189 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(POINTSAT, (yyvsp[-2].u.expr), (yyvsp[0].u.expr));
-}
-#line 9496 "built/tmp/cppBison.yxx.c"
- break;
-
- case 746: /* formal_const_expr: '(' const_expr_comma ')' */
-#line 4193 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = (yyvsp[-1].u.expr);
-}
-#line 9504 "built/tmp/cppBison.yxx.c"
- break;
-
- case 747: /* formal_const_operand: INTEGER */
-#line 4200 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression((yyvsp[0].u.integer));
-}
-#line 9512 "built/tmp/cppBison.yxx.c"
- break;
-
- case 748: /* formal_const_operand: KW_TRUE */
-#line 4204 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(true);
-}
-#line 9520 "built/tmp/cppBison.yxx.c"
- break;
-
- case 749: /* formal_const_operand: KW_FALSE */
-#line 4208 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(false);
-}
-#line 9528 "built/tmp/cppBison.yxx.c"
- break;
-
- case 750: /* formal_const_operand: CHAR_TOK */
-#line 4212 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression((yyvsp[0].u.integer));
-}
-#line 9536 "built/tmp/cppBison.yxx.c"
- break;
-
- case 751: /* formal_const_operand: REAL */
-#line 4216 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression((yyvsp[0].u.real));
-}
-#line 9544 "built/tmp/cppBison.yxx.c"
- break;
-
- case 752: /* formal_const_operand: string_literal */
-#line 4220 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = (yyvsp[0].u.expr);
-}
-#line 9552 "built/tmp/cppBison.yxx.c"
- break;
-
- case 753: /* formal_const_operand: CUSTOM_LITERAL */
-#line 4224 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = (yyvsp[0].u.expr);
-}
-#line 9560 "built/tmp/cppBison.yxx.c"
- break;
-
- case 754: /* formal_const_operand: IDENTIFIER */
-#line 4228 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression((yyvsp[0].u.identifier), current_scope, global_scope, current_lexer);
-}
-#line 9568 "built/tmp/cppBison.yxx.c"
- break;
-
- case 755: /* formal_const_operand: KW_FINAL */
-#line 4232 "dtool/src/cppparser/cppBison.yxx"
-{
- // A variable named "final". C++11 explicitly permits this.
- CPPIdentifier *ident = new CPPIdentifier("final", (yylsp[0]));
- (yyval.u.expr) = new CPPExpression(ident, current_scope, global_scope, current_lexer);
-}
-#line 9578 "built/tmp/cppBison.yxx.c"
- break;
-
- case 756: /* formal_const_operand: KW_OVERRIDE */
-#line 4238 "dtool/src/cppparser/cppBison.yxx"
-{
- // A variable named "override". C++11 explicitly permits this.
- CPPIdentifier *ident = new CPPIdentifier("override", (yylsp[0]));
- (yyval.u.expr) = new CPPExpression(ident, current_scope, global_scope, current_lexer);
-}
-#line 9588 "built/tmp/cppBison.yxx.c"
- break;
-
- case 757: /* formal_const_operand: KW_NULLPTR */
-#line 4244 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression(CPPExpression::get_nullptr());
-}
-#line 9596 "built/tmp/cppBison.yxx.c"
- break;
-
- case 758: /* capture_list: empty */
-#line 4252 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.closure_type) = new CPPClosureType();
-}
-#line 9604 "built/tmp/cppBison.yxx.c"
- break;
-
- case 759: /* capture_list: '=' */
-#line 4256 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.closure_type) = new CPPClosureType(CPPClosureType::CT_by_value);
-}
-#line 9612 "built/tmp/cppBison.yxx.c"
- break;
-
- case 760: /* capture_list: '&' */
-#line 4260 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.closure_type) = new CPPClosureType(CPPClosureType::CT_by_reference);
-}
-#line 9620 "built/tmp/cppBison.yxx.c"
- break;
-
- case 761: /* capture_list: capture maybe_initialize */
-#line 4264 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.closure_type) = new CPPClosureType();
- (yyvsp[-1].u.capture)->_initializer = (yyvsp[0].u.expr);
- (yyval.u.closure_type)->_captures.push_back(*(yyvsp[-1].u.capture));
- delete (yyvsp[-1].u.capture);
-}
-#line 9631 "built/tmp/cppBison.yxx.c"
- break;
-
- case 762: /* capture_list: capture_list ',' capture maybe_initialize */
-#line 4271 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.closure_type) = (yyvsp[-3].u.closure_type);
- (yyvsp[-1].u.capture)->_initializer = (yyvsp[0].u.expr);
- (yyval.u.closure_type)->_captures.push_back(*(yyvsp[-1].u.capture));
- delete (yyvsp[-1].u.capture);
-}
-#line 9642 "built/tmp/cppBison.yxx.c"
- break;
-
- case 763: /* capture: '&' name */
-#line 4281 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.capture) = new CPPClosureType::Capture;
- (yyval.u.capture)->_name = (yyvsp[0].u.identifier)->get_simple_name();
- (yyval.u.capture)->_type = CPPClosureType::CT_by_reference;
-}
-#line 9652 "built/tmp/cppBison.yxx.c"
- break;
-
- case 764: /* capture: '&' name ELLIPSIS */
-#line 4287 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.capture) = new CPPClosureType::Capture;
- (yyval.u.capture)->_name = (yyvsp[-1].u.identifier)->get_simple_name();
- (yyval.u.capture)->_type = CPPClosureType::CT_by_reference;
-}
-#line 9662 "built/tmp/cppBison.yxx.c"
- break;
-
- case 765: /* capture: name */
-#line 4293 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.capture) = new CPPClosureType::Capture;
- (yyval.u.capture)->_name = (yyvsp[0].u.identifier)->get_simple_name();
- if ((yyval.u.capture)->_name == "this") {
- (yyval.u.capture)->_type = CPPClosureType::CT_by_reference;
- } else {
- (yyval.u.capture)->_type = CPPClosureType::CT_by_value;
- }
-}
-#line 9676 "built/tmp/cppBison.yxx.c"
- break;
-
- case 766: /* capture: '*' name */
-#line 4303 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.capture) = new CPPClosureType::Capture;
- (yyval.u.capture)->_name = (yyvsp[0].u.identifier)->get_simple_name();
- (yyval.u.capture)->_type = CPPClosureType::CT_by_value;
- if ((yyval.u.capture)->_name != "this") {
- yywarning("only capture name 'this' may be preceded by an asterisk", (yylsp[0]));
- }
-}
-#line 9689 "built/tmp/cppBison.yxx.c"
- break;
-
- case 767: /* class_derivation_name: name */
-#line 4315 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPType *type = (yyvsp[0].u.identifier)->find_type(current_scope, global_scope, true);
- if (type == nullptr) {
- type = CPPType::new_type(new CPPTBDType((yyvsp[0].u.identifier)));
- }
- (yyval.u.type) = type;
-}
-#line 9701 "built/tmp/cppBison.yxx.c"
- break;
-
- case 768: /* class_derivation_name: KW_TYPENAME name */
-#line 4323 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.type) = CPPType::new_type(new CPPTBDType((yyvsp[0].u.identifier)));
-}
-#line 9709 "built/tmp/cppBison.yxx.c"
- break;
-
- case 769: /* class_derivation_name: name ELLIPSIS */
-#line 4327 "dtool/src/cppparser/cppBison.yxx"
-{
- CPPClassTemplateParameter *ctp = new CPPClassTemplateParameter((yyvsp[-1].u.identifier));
- ctp->_packed = true;
- (yyval.u.type) = CPPType::new_type(ctp);
-}
-#line 9719 "built/tmp/cppBison.yxx.c"
- break;
-
- case 770: /* name: IDENTIFIER */
-#line 4357 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.identifier) = (yyvsp[0].u.identifier);
-}
-#line 9727 "built/tmp/cppBison.yxx.c"
- break;
-
- case 771: /* name: TYPENAME_IDENTIFIER */
-#line 4361 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.identifier) = (yyvsp[0].u.identifier);
-}
-#line 9735 "built/tmp/cppBison.yxx.c"
- break;
-
- case 772: /* name: TYPEPACK_IDENTIFIER */
-#line 4365 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.identifier) = (yyvsp[0].u.identifier);
-}
-#line 9743 "built/tmp/cppBison.yxx.c"
- break;
-
- case 773: /* name: KW_FINAL */
-#line 4369 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.identifier) = new CPPIdentifier("final", (yylsp[0]));
-}
-#line 9751 "built/tmp/cppBison.yxx.c"
- break;
-
- case 774: /* name: KW_OVERRIDE */
-#line 4373 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.identifier) = new CPPIdentifier("override", (yylsp[0]));
-}
-#line 9759 "built/tmp/cppBison.yxx.c"
- break;
-
- case 775: /* name: KW_SIGNED */
-#line 4377 "dtool/src/cppparser/cppBison.yxx"
-{
- // This is not a keyword in Python, so it is useful to be able to use this
- // in MAKE_PROPERTY definitions, etc.
- (yyval.u.identifier) = new CPPIdentifier("signed", (yylsp[0]));
-}
-#line 9769 "built/tmp/cppBison.yxx.c"
- break;
-
- case 776: /* name: KW_FLOAT */
-#line 4383 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.identifier) = new CPPIdentifier("float", (yylsp[0]));
-}
-#line 9777 "built/tmp/cppBison.yxx.c"
- break;
-
- case 777: /* name: KW_PUBLIC */
-#line 4387 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.identifier) = new CPPIdentifier("public", (yylsp[0]));
-}
-#line 9785 "built/tmp/cppBison.yxx.c"
- break;
-
- case 778: /* name: KW_PRIVATE */
-#line 4391 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.identifier) = new CPPIdentifier("private", (yylsp[0]));
-}
-#line 9793 "built/tmp/cppBison.yxx.c"
- break;
-
- case 779: /* name: KW_STATIC */
-#line 4395 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.identifier) = new CPPIdentifier("static", (yylsp[0]));
-}
-#line 9801 "built/tmp/cppBison.yxx.c"
- break;
-
- case 780: /* name: KW_DEFAULT */
-#line 4399 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.identifier) = new CPPIdentifier("default", (yylsp[0]));
-}
-#line 9809 "built/tmp/cppBison.yxx.c"
- break;
-
- case 781: /* name_no_final: IDENTIFIER */
-#line 4410 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.identifier) = (yyvsp[0].u.identifier);
-}
-#line 9817 "built/tmp/cppBison.yxx.c"
- break;
-
- case 782: /* name_no_final: TYPENAME_IDENTIFIER */
-#line 4414 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.identifier) = (yyvsp[0].u.identifier);
-}
-#line 9825 "built/tmp/cppBison.yxx.c"
- break;
-
- case 783: /* name_no_final: TYPEPACK_IDENTIFIER */
-#line 4418 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.identifier) = (yyvsp[0].u.identifier);
-}
-#line 9833 "built/tmp/cppBison.yxx.c"
- break;
-
- case 784: /* name_no_final: KW_OVERRIDE */
-#line 4422 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.identifier) = new CPPIdentifier("override", (yylsp[0]));
-}
-#line 9841 "built/tmp/cppBison.yxx.c"
- break;
-
- case 785: /* string_literal: SIMPLE_STRING */
-#line 4430 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = new CPPExpression((yyvsp[0].str));
-}
-#line 9849 "built/tmp/cppBison.yxx.c"
- break;
-
- case 786: /* string_literal: STRING_LITERAL */
-#line 4434 "dtool/src/cppparser/cppBison.yxx"
-{
- (yyval.u.expr) = (yyvsp[0].u.expr);
-}
-#line 9857 "built/tmp/cppBison.yxx.c"
- break;
-
- case 787: /* string_literal: string_literal SIMPLE_STRING */
-#line 4438 "dtool/src/cppparser/cppBison.yxx"
-{
- // The right string takes on the literal type of the left.
- (yyval.u.expr) = (yyvsp[-1].u.expr);
- (yyval.u.expr)->_str += (yyvsp[0].str);
-}
-#line 9867 "built/tmp/cppBison.yxx.c"
- break;
-
- case 788: /* string_literal: string_literal STRING_LITERAL */
-#line 4444 "dtool/src/cppparser/cppBison.yxx"
-{
- // We have to check that the two literal types match up.
- (yyval.u.expr) = (yyvsp[-1].u.expr);
- if ((yyvsp[0].u.expr)->_type != CPPExpression::T_string && (yyvsp[0].u.expr)->_type != (yyvsp[-1].u.expr)->_type) {
- yywarning("cannot concatenate two string literals of different types", (yyloc));
- }
- (yyval.u.expr)->_str += (yyvsp[0].u.expr)->_str;
-}
-#line 9880 "built/tmp/cppBison.yxx.c"
- break;
-
-
-#line 9884 "built/tmp/cppBison.yxx.c"
-
- default: break;
- }
- /* User semantic actions sometimes alter yychar, and that requires
- that yytoken be updated with the new translation. We take the
- approach of translating immediately before every use of yytoken.
- One alternative is translating here after every semantic action,
- but that translation would be missed if the semantic action invokes
- YYABORT, YYACCEPT, or YYERROR immediately after altering yychar or
- if it invokes YYBACKUP. In the case of YYABORT or YYACCEPT, an
- incorrect destructor might then be invoked immediately. In the
- case of YYERROR or YYBACKUP, subsequent parser actions might lead
- to an incorrect destructor call or verbose syntax error message
- before the lookahead is translated. */
- YY_SYMBOL_PRINT ("-> $$ =", YY_CAST (yysymbol_kind_t, yyr1[yyn]), &yyval, &yyloc);
-
- YYPOPSTACK (yylen);
- yylen = 0;
-
- *++yyvsp = yyval;
- *++yylsp = yyloc;
-
- /* Now 'shift' the result of the reduction. Determine what state
- that goes to, based on the state we popped back to and the rule
- number reduced by. */
- {
- const int yylhs = yyr1[yyn] - YYNTOKENS;
- const int yyi = yypgoto[yylhs] + *yyssp;
- yystate = (0 <= yyi && yyi <= YYLAST && yycheck[yyi] == *yyssp
- ? yytable[yyi]
- : yydefgoto[yylhs]);
- }
-
- goto yynewstate;
-
-
-/*--------------------------------------.
-| yyerrlab -- here on detecting error. |
-`--------------------------------------*/
-yyerrlab:
- /* Make sure we have latest lookahead translation. See comments at
- user semantic actions for why this is necessary. */
- yytoken = yychar == YYEMPTY ? YYSYMBOL_YYEMPTY : YYTRANSLATE (yychar);
- /* If not already recovering from an error, report this error. */
- if (!yyerrstatus)
- {
- ++yynerrs;
- yyerror (&yylloc, YY_("syntax error"));
- }
-
- yyerror_range[1] = yylloc;
- if (yyerrstatus == 3)
- {
- /* If just tried and failed to reuse lookahead token after an
- error, discard it. */
-
- if (yychar <= YYEOF)
- {
- /* Return failure if at end of input. */
- if (yychar == YYEOF)
- YYABORT;
- }
- else
- {
- yydestruct ("Error: discarding",
- yytoken, &yylval, &yylloc);
- yychar = YYEMPTY;
- }
- }
-
- /* Else will try to reuse lookahead token after shifting the error
- token. */
- goto yyerrlab1;
-
-
-/*---------------------------------------------------.
-| yyerrorlab -- error raised explicitly by YYERROR. |
-`---------------------------------------------------*/
-yyerrorlab:
- /* Pacify compilers when the user code never invokes YYERROR and the
- label yyerrorlab therefore never appears in user code. */
- if (0)
- YYERROR;
- ++yynerrs;
-
- /* Do not reclaim the symbols of the rule whose action triggered
- this YYERROR. */
- YYPOPSTACK (yylen);
- yylen = 0;
- YY_STACK_PRINT (yyss, yyssp);
- yystate = *yyssp;
- goto yyerrlab1;
-
-
-/*-------------------------------------------------------------.
-| yyerrlab1 -- common code for both syntax error and YYERROR. |
-`-------------------------------------------------------------*/
-yyerrlab1:
- yyerrstatus = 3; /* Each real token shifted decrements this. */
-
- /* Pop stack until we find a state that shifts the error token. */
- for (;;)
- {
- yyn = yypact[yystate];
- if (!yypact_value_is_default (yyn))
- {
- yyn += YYSYMBOL_YYerror;
- if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYSYMBOL_YYerror)
- {
- yyn = yytable[yyn];
- if (0 < yyn)
- break;
- }
- }
-
- /* Pop the current state because it cannot handle the error token. */
- if (yyssp == yyss)
- YYABORT;
-
- yyerror_range[1] = *yylsp;
- yydestruct ("Error: popping",
- YY_ACCESSING_SYMBOL (yystate), yyvsp, yylsp);
- YYPOPSTACK (1);
- yystate = *yyssp;
- YY_STACK_PRINT (yyss, yyssp);
- }
-
- YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
- *++yyvsp = yylval;
- YY_IGNORE_MAYBE_UNINITIALIZED_END
-
- yyerror_range[2] = yylloc;
- ++yylsp;
- YYLLOC_DEFAULT (*yylsp, yyerror_range, 2);
-
- /* Shift the error token. */
- YY_SYMBOL_PRINT ("Shifting", YY_ACCESSING_SYMBOL (yyn), yyvsp, yylsp);
-
- yystate = yyn;
- goto yynewstate;
-
-
-/*-------------------------------------.
-| yyacceptlab -- YYACCEPT comes here. |
-`-------------------------------------*/
-yyacceptlab:
- yyresult = 0;
- goto yyreturnlab;
-
-
-/*-----------------------------------.
-| yyabortlab -- YYABORT comes here. |
-`-----------------------------------*/
-yyabortlab:
- yyresult = 1;
- goto yyreturnlab;
-
-
-/*-----------------------------------------------------------.
-| yyexhaustedlab -- YYNOMEM (memory exhaustion) comes here. |
-`-----------------------------------------------------------*/
-yyexhaustedlab:
- yyerror (&yylloc, YY_("memory exhausted"));
- yyresult = 2;
- goto yyreturnlab;
-
-
-/*----------------------------------------------------------.
-| yyreturnlab -- parsing is finished, clean up and return. |
-`----------------------------------------------------------*/
-yyreturnlab:
- if (yychar != YYEMPTY)
- {
- /* Make sure we have latest lookahead translation. See comments at
- user semantic actions for why this is necessary. */
- yytoken = YYTRANSLATE (yychar);
- yydestruct ("Cleanup: discarding lookahead",
- yytoken, &yylval, &yylloc);
- }
- /* Do not reclaim the symbols of the rule whose action triggered
- this YYABORT or YYACCEPT. */
- YYPOPSTACK (yylen);
- YY_STACK_PRINT (yyss, yyssp);
- while (yyssp != yyss)
- {
- yydestruct ("Cleanup: popping",
- YY_ACCESSING_SYMBOL (+*yyssp), yyvsp, yylsp);
- YYPOPSTACK (1);
- }
-#ifndef yyoverflow
- if (yyss != yyssa)
- YYSTACK_FREE (yyss);
-#endif
-
- return yyresult;
-}
-
diff --git a/dtool/src/cppparser/cppBison.h.prebuilt b/dtool/src/cppparser/cppBison.h.prebuilt
deleted file mode 100644
index 78032c0153..0000000000
--- a/dtool/src/cppparser/cppBison.h.prebuilt
+++ /dev/null
@@ -1,394 +0,0 @@
-/* A Bison parser, made by GNU Bison 3.8.2. */
-
-/* Bison interface for Yacc-like parsers in C
-
- Copyright (C) 1984, 1989-1990, 2000-2015, 2018-2021 Free Software Foundation,
- Inc.
-
- This program is free software: you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation, either version 3 of the License, or
- (at your option) any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program. If not, see . */
-
-/* As a special exception, you may create a larger work that contains
- part or all of the Bison parser skeleton and distribute that work
- under terms of your choice, so long as that work isn't itself a
- parser generator using the skeleton or a modified version thereof
- as a parser skeleton. Alternatively, if you modify or redistribute
- the parser skeleton itself, you may (at your option) remove this
- special exception, which will cause the skeleton and the resulting
- Bison output files to be licensed under the GNU General Public
- License without this special exception.
-
- This special exception was added by the Free Software Foundation in
- version 2.2 of Bison. */
-
-/* DO NOT RELY ON FEATURES THAT ARE NOT DOCUMENTED in the manual,
- especially those whose name start with YY_ or yy_. They are
- private implementation details that can be changed or removed. */
-
-#ifndef YY_CPPYY_BUILT_TMP_CPPBISON_YXX_H_INCLUDED
-# define YY_CPPYY_BUILT_TMP_CPPBISON_YXX_H_INCLUDED
-/* Debug traces. */
-#ifndef YYDEBUG
-# define YYDEBUG 0
-#endif
-#if YYDEBUG
-extern int cppyydebug;
-#endif
-
-/* Token kinds. */
-#ifndef YYTOKENTYPE
-# define YYTOKENTYPE
- enum yytokentype
- {
- YYEMPTY = -2,
- YYEOF = 0, /* "end of file" */
- YYerror = 256, /* error */
- YYUNDEF = 257, /* "invalid token" */
- REAL = 258, /* REAL */
- INTEGER = 259, /* INTEGER */
- CHAR_TOK = 260, /* CHAR_TOK */
- SIMPLE_STRING = 261, /* SIMPLE_STRING */
- SIMPLE_IDENTIFIER = 262, /* SIMPLE_IDENTIFIER */
- STRING_LITERAL = 263, /* STRING_LITERAL */
- CUSTOM_LITERAL = 264, /* CUSTOM_LITERAL */
- IDENTIFIER = 265, /* IDENTIFIER */
- TYPENAME_IDENTIFIER = 266, /* TYPENAME_IDENTIFIER */
- TYPEPACK_IDENTIFIER = 267, /* TYPEPACK_IDENTIFIER */
- SCOPING = 268, /* SCOPING */
- TYPEDEFNAME = 269, /* TYPEDEFNAME */
- ELLIPSIS = 270, /* ELLIPSIS */
- OROR = 271, /* OROR */
- ANDAND = 272, /* ANDAND */
- EQCOMPARE = 273, /* EQCOMPARE */
- NECOMPARE = 274, /* NECOMPARE */
- LECOMPARE = 275, /* LECOMPARE */
- GECOMPARE = 276, /* GECOMPARE */
- SPACESHIP = 277, /* SPACESHIP */
- LSHIFT = 278, /* LSHIFT */
- RSHIFT = 279, /* RSHIFT */
- POINTSAT_STAR = 280, /* POINTSAT_STAR */
- DOT_STAR = 281, /* DOT_STAR */
- UNARY = 282, /* UNARY */
- UNARY_NOT = 283, /* UNARY_NOT */
- UNARY_NEGATE = 284, /* UNARY_NEGATE */
- UNARY_MINUS = 285, /* UNARY_MINUS */
- UNARY_PLUS = 286, /* UNARY_PLUS */
- UNARY_STAR = 287, /* UNARY_STAR */
- UNARY_REF = 288, /* UNARY_REF */
- POINTSAT = 289, /* POINTSAT */
- SCOPE = 290, /* SCOPE */
- PLUSPLUS = 291, /* PLUSPLUS */
- MINUSMINUS = 292, /* MINUSMINUS */
- TIMESEQUAL = 293, /* TIMESEQUAL */
- DIVIDEEQUAL = 294, /* DIVIDEEQUAL */
- MODEQUAL = 295, /* MODEQUAL */
- PLUSEQUAL = 296, /* PLUSEQUAL */
- MINUSEQUAL = 297, /* MINUSEQUAL */
- OREQUAL = 298, /* OREQUAL */
- ANDEQUAL = 299, /* ANDEQUAL */
- XOREQUAL = 300, /* XOREQUAL */
- LSHIFTEQUAL = 301, /* LSHIFTEQUAL */
- RSHIFTEQUAL = 302, /* RSHIFTEQUAL */
- ATTR_LEFT = 303, /* ATTR_LEFT */
- ATTR_RIGHT = 304, /* ATTR_RIGHT */
- KW_ALIGNAS = 305, /* KW_ALIGNAS */
- KW_ALIGNOF = 306, /* KW_ALIGNOF */
- KW_AUTO = 307, /* KW_AUTO */
- KW_BEGIN_PUBLISH = 308, /* KW_BEGIN_PUBLISH */
- KW_BLOCKING = 309, /* KW_BLOCKING */
- KW_BOOL = 310, /* KW_BOOL */
- KW_BUILTIN_VA_LIST = 311, /* KW_BUILTIN_VA_LIST */
- KW_CATCH = 312, /* KW_CATCH */
- KW_CHAR = 313, /* KW_CHAR */
- KW_CHAR8_T = 314, /* KW_CHAR8_T */
- KW_CHAR16_T = 315, /* KW_CHAR16_T */
- KW_CHAR32_T = 316, /* KW_CHAR32_T */
- KW_CLASS = 317, /* KW_CLASS */
- KW_CONST = 318, /* KW_CONST */
- KW_CONSTEVAL = 319, /* KW_CONSTEVAL */
- KW_CONSTEXPR = 320, /* KW_CONSTEXPR */
- KW_CONSTINIT = 321, /* KW_CONSTINIT */
- KW_CONST_CAST = 322, /* KW_CONST_CAST */
- KW_DECLTYPE = 323, /* KW_DECLTYPE */
- KW_DEFAULT = 324, /* KW_DEFAULT */
- KW_DELETE = 325, /* KW_DELETE */
- KW_DOUBLE = 326, /* KW_DOUBLE */
- KW_DYNAMIC_CAST = 327, /* KW_DYNAMIC_CAST */
- KW_ELSE = 328, /* KW_ELSE */
- KW_END_PUBLISH = 329, /* KW_END_PUBLISH */
- KW_ENUM = 330, /* KW_ENUM */
- KW_EXTENSION = 331, /* KW_EXTENSION */
- KW_EXTERN = 332, /* KW_EXTERN */
- KW_EXPLICIT = 333, /* KW_EXPLICIT */
- KW_EXPLICIT_LPAREN = 334, /* KW_EXPLICIT_LPAREN */
- KW_PUBLISHED = 335, /* KW_PUBLISHED */
- KW_FALSE = 336, /* KW_FALSE */
- KW_FINAL = 337, /* KW_FINAL */
- KW_FLOAT = 338, /* KW_FLOAT */
- KW_FRIEND = 339, /* KW_FRIEND */
- KW_FOR = 340, /* KW_FOR */
- KW_GOTO = 341, /* KW_GOTO */
- KW_HAS_VIRTUAL_DESTRUCTOR = 342, /* KW_HAS_VIRTUAL_DESTRUCTOR */
- KW_IF = 343, /* KW_IF */
- KW_INLINE = 344, /* KW_INLINE */
- KW_INT = 345, /* KW_INT */
- KW_IS_ABSTRACT = 346, /* KW_IS_ABSTRACT */
- KW_IS_BASE_OF = 347, /* KW_IS_BASE_OF */
- KW_IS_CLASS = 348, /* KW_IS_CLASS */
- KW_IS_CONSTRUCTIBLE = 349, /* KW_IS_CONSTRUCTIBLE */
- KW_IS_CONVERTIBLE_TO = 350, /* KW_IS_CONVERTIBLE_TO */
- KW_IS_DESTRUCTIBLE = 351, /* KW_IS_DESTRUCTIBLE */
- KW_IS_EMPTY = 352, /* KW_IS_EMPTY */
- KW_IS_ENUM = 353, /* KW_IS_ENUM */
- KW_IS_FINAL = 354, /* KW_IS_FINAL */
- KW_IS_FUNDAMENTAL = 355, /* KW_IS_FUNDAMENTAL */
- KW_IS_POD = 356, /* KW_IS_POD */
- KW_IS_POLYMORPHIC = 357, /* KW_IS_POLYMORPHIC */
- KW_IS_STANDARD_LAYOUT = 358, /* KW_IS_STANDARD_LAYOUT */
- KW_IS_TRIVIAL = 359, /* KW_IS_TRIVIAL */
- KW_IS_TRIVIALLY_COPYABLE = 360, /* KW_IS_TRIVIALLY_COPYABLE */
- KW_IS_UNION = 361, /* KW_IS_UNION */
- KW_LONG = 362, /* KW_LONG */
- KW_MAKE_MAP_KEYS_SEQ = 363, /* KW_MAKE_MAP_KEYS_SEQ */
- KW_MAKE_MAP_PROPERTY = 364, /* KW_MAKE_MAP_PROPERTY */
- KW_MAKE_PROPERTY = 365, /* KW_MAKE_PROPERTY */
- KW_MAKE_PROPERTY2 = 366, /* KW_MAKE_PROPERTY2 */
- KW_MAKE_SEQ = 367, /* KW_MAKE_SEQ */
- KW_MAKE_SEQ_PROPERTY = 368, /* KW_MAKE_SEQ_PROPERTY */
- KW_MUTABLE = 369, /* KW_MUTABLE */
- KW_NAMESPACE = 370, /* KW_NAMESPACE */
- KW_NEW = 371, /* KW_NEW */
- KW_NOEXCEPT = 372, /* KW_NOEXCEPT */
- KW_NOEXCEPT_LPAREN = 373, /* KW_NOEXCEPT_LPAREN */
- KW_NULLPTR = 374, /* KW_NULLPTR */
- KW_OPERATOR = 375, /* KW_OPERATOR */
- KW_OVERRIDE = 376, /* KW_OVERRIDE */
- KW_PRIVATE = 377, /* KW_PRIVATE */
- KW_PROTECTED = 378, /* KW_PROTECTED */
- KW_PUBLIC = 379, /* KW_PUBLIC */
- KW_REGISTER = 380, /* KW_REGISTER */
- KW_REINTERPRET_CAST = 381, /* KW_REINTERPRET_CAST */
- KW_RESTRICT = 382, /* KW_RESTRICT */
- KW_RETURN = 383, /* KW_RETURN */
- KW_SHORT = 384, /* KW_SHORT */
- KW_SIGNED = 385, /* KW_SIGNED */
- KW_SIZEOF = 386, /* KW_SIZEOF */
- KW_STATIC = 387, /* KW_STATIC */
- KW_STATIC_ASSERT = 388, /* KW_STATIC_ASSERT */
- KW_STATIC_CAST = 389, /* KW_STATIC_CAST */
- KW_STRUCT = 390, /* KW_STRUCT */
- KW_TEMPLATE = 391, /* KW_TEMPLATE */
- KW_THREAD_LOCAL = 392, /* KW_THREAD_LOCAL */
- KW_THROW = 393, /* KW_THROW */
- KW_TRUE = 394, /* KW_TRUE */
- KW_TRY = 395, /* KW_TRY */
- KW_TYPEDEF = 396, /* KW_TYPEDEF */
- KW_TYPEID = 397, /* KW_TYPEID */
- KW_TYPENAME = 398, /* KW_TYPENAME */
- KW_UNDERLYING_TYPE = 399, /* KW_UNDERLYING_TYPE */
- KW_UNION = 400, /* KW_UNION */
- KW_UNSIGNED = 401, /* KW_UNSIGNED */
- KW_USING = 402, /* KW_USING */
- KW_VIRTUAL = 403, /* KW_VIRTUAL */
- KW_VOID = 404, /* KW_VOID */
- KW_VOLATILE = 405, /* KW_VOLATILE */
- KW_WCHAR_T = 406, /* KW_WCHAR_T */
- KW_WHILE = 407, /* KW_WHILE */
- START_CPP = 408, /* START_CPP */
- START_CONST_EXPR = 409, /* START_CONST_EXPR */
- START_TYPE = 410 /* START_TYPE */
- };
- typedef enum yytokentype yytoken_kind_t;
-#endif
-/* Token kinds. */
-#define YYEMPTY -2
-#define YYEOF 0
-#define YYerror 256
-#define YYUNDEF 257
-#define REAL 258
-#define INTEGER 259
-#define CHAR_TOK 260
-#define SIMPLE_STRING 261
-#define SIMPLE_IDENTIFIER 262
-#define STRING_LITERAL 263
-#define CUSTOM_LITERAL 264
-#define IDENTIFIER 265
-#define TYPENAME_IDENTIFIER 266
-#define TYPEPACK_IDENTIFIER 267
-#define SCOPING 268
-#define TYPEDEFNAME 269
-#define ELLIPSIS 270
-#define OROR 271
-#define ANDAND 272
-#define EQCOMPARE 273
-#define NECOMPARE 274
-#define LECOMPARE 275
-#define GECOMPARE 276
-#define SPACESHIP 277
-#define LSHIFT 278
-#define RSHIFT 279
-#define POINTSAT_STAR 280
-#define DOT_STAR 281
-#define UNARY 282
-#define UNARY_NOT 283
-#define UNARY_NEGATE 284
-#define UNARY_MINUS 285
-#define UNARY_PLUS 286
-#define UNARY_STAR 287
-#define UNARY_REF 288
-#define POINTSAT 289
-#define SCOPE 290
-#define PLUSPLUS 291
-#define MINUSMINUS 292
-#define TIMESEQUAL 293
-#define DIVIDEEQUAL 294
-#define MODEQUAL 295
-#define PLUSEQUAL 296
-#define MINUSEQUAL 297
-#define OREQUAL 298
-#define ANDEQUAL 299
-#define XOREQUAL 300
-#define LSHIFTEQUAL 301
-#define RSHIFTEQUAL 302
-#define ATTR_LEFT 303
-#define ATTR_RIGHT 304
-#define KW_ALIGNAS 305
-#define KW_ALIGNOF 306
-#define KW_AUTO 307
-#define KW_BEGIN_PUBLISH 308
-#define KW_BLOCKING 309
-#define KW_BOOL 310
-#define KW_BUILTIN_VA_LIST 311
-#define KW_CATCH 312
-#define KW_CHAR 313
-#define KW_CHAR8_T 314
-#define KW_CHAR16_T 315
-#define KW_CHAR32_T 316
-#define KW_CLASS 317
-#define KW_CONST 318
-#define KW_CONSTEVAL 319
-#define KW_CONSTEXPR 320
-#define KW_CONSTINIT 321
-#define KW_CONST_CAST 322
-#define KW_DECLTYPE 323
-#define KW_DEFAULT 324
-#define KW_DELETE 325
-#define KW_DOUBLE 326
-#define KW_DYNAMIC_CAST 327
-#define KW_ELSE 328
-#define KW_END_PUBLISH 329
-#define KW_ENUM 330
-#define KW_EXTENSION 331
-#define KW_EXTERN 332
-#define KW_EXPLICIT 333
-#define KW_EXPLICIT_LPAREN 334
-#define KW_PUBLISHED 335
-#define KW_FALSE 336
-#define KW_FINAL 337
-#define KW_FLOAT 338
-#define KW_FRIEND 339
-#define KW_FOR 340
-#define KW_GOTO 341
-#define KW_HAS_VIRTUAL_DESTRUCTOR 342
-#define KW_IF 343
-#define KW_INLINE 344
-#define KW_INT 345
-#define KW_IS_ABSTRACT 346
-#define KW_IS_BASE_OF 347
-#define KW_IS_CLASS 348
-#define KW_IS_CONSTRUCTIBLE 349
-#define KW_IS_CONVERTIBLE_TO 350
-#define KW_IS_DESTRUCTIBLE 351
-#define KW_IS_EMPTY 352
-#define KW_IS_ENUM 353
-#define KW_IS_FINAL 354
-#define KW_IS_FUNDAMENTAL 355
-#define KW_IS_POD 356
-#define KW_IS_POLYMORPHIC 357
-#define KW_IS_STANDARD_LAYOUT 358
-#define KW_IS_TRIVIAL 359
-#define KW_IS_TRIVIALLY_COPYABLE 360
-#define KW_IS_UNION 361
-#define KW_LONG 362
-#define KW_MAKE_MAP_KEYS_SEQ 363
-#define KW_MAKE_MAP_PROPERTY 364
-#define KW_MAKE_PROPERTY 365
-#define KW_MAKE_PROPERTY2 366
-#define KW_MAKE_SEQ 367
-#define KW_MAKE_SEQ_PROPERTY 368
-#define KW_MUTABLE 369
-#define KW_NAMESPACE 370
-#define KW_NEW 371
-#define KW_NOEXCEPT 372
-#define KW_NOEXCEPT_LPAREN 373
-#define KW_NULLPTR 374
-#define KW_OPERATOR 375
-#define KW_OVERRIDE 376
-#define KW_PRIVATE 377
-#define KW_PROTECTED 378
-#define KW_PUBLIC 379
-#define KW_REGISTER 380
-#define KW_REINTERPRET_CAST 381
-#define KW_RESTRICT 382
-#define KW_RETURN 383
-#define KW_SHORT 384
-#define KW_SIGNED 385
-#define KW_SIZEOF 386
-#define KW_STATIC 387
-#define KW_STATIC_ASSERT 388
-#define KW_STATIC_CAST 389
-#define KW_STRUCT 390
-#define KW_TEMPLATE 391
-#define KW_THREAD_LOCAL 392
-#define KW_THROW 393
-#define KW_TRUE 394
-#define KW_TRY 395
-#define KW_TYPEDEF 396
-#define KW_TYPEID 397
-#define KW_TYPENAME 398
-#define KW_UNDERLYING_TYPE 399
-#define KW_UNION 400
-#define KW_UNSIGNED 401
-#define KW_USING 402
-#define KW_VIRTUAL 403
-#define KW_VOID 404
-#define KW_VOLATILE 405
-#define KW_WCHAR_T 406
-#define KW_WHILE 407
-#define START_CPP 408
-#define START_CONST_EXPR 409
-#define START_TYPE 410
-
-/* Value type. */
-
-/* Location type. */
-#if ! defined YYLTYPE && ! defined YYLTYPE_IS_DECLARED
-typedef struct YYLTYPE YYLTYPE;
-struct YYLTYPE
-{
- int first_line;
- int first_column;
- int last_line;
- int last_column;
-};
-# define YYLTYPE_IS_DECLARED 1
-# define YYLTYPE_IS_TRIVIAL 1
-#endif
-
-
-
-
-int cppyyparse (void);
-
-
-#endif /* !YY_CPPYY_BUILT_TMP_CPPBISON_YXX_H_INCLUDED */
diff --git a/dtool/src/cppparser/cppBison.yxx b/dtool/src/cppparser/cppBison.yxx
deleted file mode 100644
index 8a249d1185..0000000000
--- a/dtool/src/cppparser/cppBison.yxx
+++ /dev/null
@@ -1,4455 +0,0 @@
-/**
- * @file cppBison.yxx
- * @author drose
- * @date 1999-01-16
- */
-
-%{
-
-#include "cppBisonDefs.h"
-#include "cppParser.h"
-#include "cppClosureType.h"
-#include "cppExpression.h"
-#include "cppSimpleType.h"
-#include "cppExtensionType.h"
-#include "cppStructType.h"
-#include "cppEnumType.h"
-#include "cppFunctionType.h"
-#include "cppTBDType.h"
-#include "cppMakeProperty.h"
-#include "cppMakeSeq.h"
-#include "cppParameterList.h"
-#include "cppInstance.h"
-#include "cppClassTemplateParameter.h"
-#include "cppTemplateParameterList.h"
-#include "cppInstanceIdentifier.h"
-#include "cppTypedefType.h"
-#include "cppTypeDeclaration.h"
-#include "cppVisibility.h"
-#include "cppIdentifier.h"
-#include "cppScope.h"
-#include "cppTemplateScope.h"
-#include "cppNamespace.h"
-#include "cppUsing.h"
-
-using std::stringstream;
-using std::string;
-
-////////////////////////////////////////////////////////////////////
-// Defining the interface to the parser.
-////////////////////////////////////////////////////////////////////
-
-CPPScope *current_scope = nullptr;
-CPPScope *global_scope = nullptr;
-CPPPreprocessor *current_lexer = nullptr;
-
-static CPPStructType *current_struct = nullptr;
-static CPPEnumType *current_enum = nullptr;
-static int current_storage_class = 0;
-static CPPType *current_type = nullptr;
-static CPPExpression *current_expr = nullptr;
-static CPPAttributeList current_attributes;
-static int publish_nest_level = 0;
-static CPPVisibility publish_previous;
-static YYLTYPE publish_loc;
-
-static std::vector last_scopes;
-static std::vector last_storage_classes;
-static std::vector last_structs;
-
-int yyparse();
-
-#define YYERROR_VERBOSE
-
-static void
-yyerror(const string &msg) {
- current_lexer->error(msg, current_lexer->_last_token_loc);
-}
-
-static void
-yyerror(YYLTYPE *loc, const string &msg) {
- current_lexer->error(msg, *loc);
-}
-
-static void
-yyerror(const string &msg, YYLTYPE &loc) {
- current_lexer->error(msg, loc);
-}
-
-static void
-yywarning(const string &msg, YYLTYPE &loc) {
- current_lexer->warning(msg, loc);
-}
-
-static int
-yylex(YYSTYPE *lval, YYLTYPE *lloc) {
- CPPToken token = current_lexer->get_next_token();
- *lval = token._lval;
- *lloc = token._lloc;
- return token._token;
-}
-
-void
-parse_cpp(CPPParser *cp) {
- CPPScope *old_scope = current_scope;
- CPPScope *old_global_scope = global_scope;
- CPPPreprocessor *old_lexer = current_lexer;
-
- current_scope = cp;
- global_scope = cp;
- current_lexer = cp;
- publish_nest_level = 0;
- yyparse();
-
- if (publish_nest_level != 0) {
- yyerror("Unclosed __begin_publish", publish_loc);
- publish_nest_level = 0;
- }
-
- current_scope = old_scope;
- global_scope = old_global_scope;
- current_lexer = old_lexer;
-
-}
-
-CPPExpression *
-parse_const_expr(CPPPreprocessor *pp, CPPScope *new_current_scope,
- CPPScope *new_global_scope) {
- CPPScope *old_scope = current_scope;
- CPPScope *old_global_scope = global_scope;
- CPPPreprocessor *old_lexer = current_lexer;
- CPPExpression *old_expr = current_expr;
-
- current_scope = new_current_scope;
- global_scope = new_global_scope;
- current_expr = nullptr;
- current_lexer = pp;
- yyparse();
-
- CPPExpression *result = current_expr;
-
- current_scope = old_scope;
- global_scope = old_global_scope;
- current_lexer = old_lexer;
- current_expr = old_expr;
-
- return result;
-}
-
-CPPType *
-parse_type(CPPPreprocessor *pp, CPPScope *new_current_scope,
- CPPScope *new_global_scope) {
- CPPScope *old_scope = current_scope;
- CPPScope *old_global_scope = global_scope;
- CPPPreprocessor *old_lexer = current_lexer;
- CPPType *old_type = current_type;
-
- current_scope = new_current_scope;
- global_scope = new_global_scope;
- current_type = nullptr;
- current_lexer = pp;
- yyparse();
-
- CPPType *result = current_type;
-
- current_scope = old_scope;
- global_scope = old_global_scope;
- current_lexer = old_lexer;
- current_type = old_type;
-
- return result;
-}
-
-static void
-push_scope(CPPScope *new_scope) {
- last_scopes.push_back(current_scope);
- if (new_scope != nullptr) {
- current_scope = new_scope;
- }
-}
-
-static void
-pop_scope() {
- assert(!last_scopes.empty());
- current_scope = last_scopes.back();
- last_scopes.pop_back();
-}
-
-static void
-push_storage_class(int new_storage_class) {
- last_storage_classes.push_back(current_storage_class);
- current_storage_class = new_storage_class;
-}
-
-static void
-pop_storage_class() {
- assert(!last_storage_classes.empty());
- current_storage_class = last_storage_classes.back();
- last_storage_classes.pop_back();
-}
-
-static void
-push_struct(CPPStructType *new_struct) {
- last_structs.push_back(current_struct);
- current_struct = new_struct;
-}
-
-static void
-pop_struct() {
- assert(!last_structs.empty());
- current_struct = last_structs.back();
- last_structs.pop_back();
-}
-
-%}
-
-/* This is a bison-specific declaration to enable recursive calls to
- yyparse(). It changes the calling sequence to yylex(), passing
- pointers to the current yylval and yylloc. Bison 2.7 introduces a
- different syntax that will also pass the current yylloc to yyerror,
- but we have to support Bison versions as old as 2.5 for now. */
-/*%define api.pure full*/
-%pure-parser
-%locations
-
-%token REAL
-%token INTEGER
-%token CHAR_TOK
-%token SIMPLE_STRING SIMPLE_IDENTIFIER
-%token STRING_LITERAL CUSTOM_LITERAL
-%token IDENTIFIER TYPENAME_IDENTIFIER TYPEPACK_IDENTIFIER SCOPING
-%token TYPEDEFNAME
-
-%token ELLIPSIS
-%token OROR
-%token ANDAND
-%token EQCOMPARE
-%token NECOMPARE
-%token LECOMPARE
-%token GECOMPARE
-%token SPACESHIP
-%token LSHIFT
-%token RSHIFT
-%token POINTSAT_STAR
-%token DOT_STAR
-%token UNARY
-%token UNARY_NOT
-%token UNARY_NEGATE
-%token UNARY_MINUS
-%token UNARY_PLUS
-%token UNARY_STAR
-%token UNARY_REF
-%token POINTSAT
-%token SCOPE
-%token PLUSPLUS
-%token MINUSMINUS
-%token TIMESEQUAL
-%token DIVIDEEQUAL
-%token MODEQUAL
-%token PLUSEQUAL
-%token MINUSEQUAL
-%token OREQUAL
-%token ANDEQUAL
-%token XOREQUAL
-%token LSHIFTEQUAL
-%token RSHIFTEQUAL
-%token ATTR_LEFT
-%token ATTR_RIGHT
-
-%token KW_ALIGNAS
-%token KW_ALIGNOF
-%token KW_AUTO
-%token KW_BEGIN_PUBLISH
-%token KW_BLOCKING
-%token KW_BOOL
-%token KW_BUILTIN_VA_LIST
-%token KW_CATCH
-%token KW_CHAR
-%token KW_CHAR8_T
-%token KW_CHAR16_T
-%token KW_CHAR32_T
-%token KW_CLASS
-%token KW_CONST
-%token KW_CONSTEVAL
-%token KW_CONSTEXPR
-%token KW_CONSTINIT
-%token KW_CONST_CAST
-%token KW_DECLTYPE
-%token KW_DEFAULT
-%token KW_DELETE
-%token KW_DOUBLE
-%token KW_DYNAMIC_CAST
-%token KW_ELSE
-%token KW_END_PUBLISH
-%token KW_ENUM
-%token KW_EXTENSION
-%token KW_EXTERN
-%token KW_EXPLICIT
-%token KW_EXPLICIT_LPAREN
-%token KW_PUBLISHED
-%token KW_FALSE
-%token KW_FINAL
-%token KW_FLOAT
-%token KW_FRIEND
-%token KW_FOR
-%token KW_GOTO
-%token KW_HAS_VIRTUAL_DESTRUCTOR
-%token KW_IF
-%token KW_INLINE
-%token KW_INT
-%token KW_IS_ABSTRACT
-%token KW_IS_BASE_OF
-%token KW_IS_CLASS
-%token KW_IS_CONSTRUCTIBLE
-%token KW_IS_CONVERTIBLE_TO
-%token KW_IS_DESTRUCTIBLE
-%token KW_IS_EMPTY
-%token KW_IS_ENUM
-%token KW_IS_FINAL
-%token KW_IS_FUNDAMENTAL
-%token KW_IS_POD
-%token KW_IS_POLYMORPHIC
-%token KW_IS_STANDARD_LAYOUT
-%token KW_IS_TRIVIAL
-%token KW_IS_TRIVIALLY_COPYABLE
-%token KW_IS_UNION
-%token KW_LONG
-%token KW_MAKE_MAP_KEYS_SEQ
-%token KW_MAKE_MAP_PROPERTY
-%token KW_MAKE_PROPERTY
-%token KW_MAKE_PROPERTY2
-%token KW_MAKE_SEQ
-%token KW_MAKE_SEQ_PROPERTY
-%token KW_MUTABLE
-%token KW_NAMESPACE
-%token KW_NEW
-%token KW_NOEXCEPT
-%token KW_NOEXCEPT_LPAREN
-%token KW_NULLPTR
-%token KW_OPERATOR
-%token KW_OVERRIDE
-%token KW_PRIVATE
-%token KW_PROTECTED
-%token KW_PUBLIC
-%token KW_REGISTER
-%token KW_REINTERPRET_CAST
-%token KW_RESTRICT
-%token KW_RETURN
-%token KW_SHORT
-%token KW_SIGNED
-%token KW_SIZEOF
-%token KW_STATIC
-%token KW_STATIC_ASSERT
-%token KW_STATIC_CAST
-%token KW_STRUCT
-%token KW_TEMPLATE
-%token KW_THREAD_LOCAL
-%token KW_THROW
-%token KW_TRUE
-%token KW_TRY
-%token KW_TYPEDEF
-%token KW_TYPEID
-%token KW_TYPENAME
-%token KW_UNDERLYING_TYPE
-%token KW_UNION
-%token KW_UNSIGNED
-%token KW_USING
-%token KW_VIRTUAL
-%token KW_VOID
-%token KW_VOLATILE
-%token KW_WCHAR_T
-%token KW_WHILE
-
-/* These special tokens are used to set the starting state of the
- parser. The lexer places the appropriate one of these on the head
- of the input stream. */
-%token START_CPP
-%token START_CONST_EXPR
-%token START_TYPE
-
-%type optional_attributes
-%type attribute_specifiers
-%type attribute_specifier
-%type storage_class
-%type constructor_prototype
-%type function_prototype
-%type function_post
-%type function_operator
-%type template_formal_parameter
-%type template_formal_parameter_type
-%type instance_identifier
-%type instance_identifier_and_maybe_trailing_return_type
-%type function_parameter_list
-%type function_parameters
-%type formal_parameter_list
-%type formal_parameters
-%type capture_list
-%type capture
-%type template_parameter_maybe_initialize
-%type maybe_initialize
-%type maybe_initialize_or_constructor_body
-%type maybe_initialize_or_function_body
-%type function_parameter
-%type formal_parameter
-%type not_paren_formal_parameter_identifier
-%type formal_parameter_identifier
-%type parameter_pack_identifier
-%type not_paren_empty_instance_identifier
-%type empty_instance_identifier
-%type type type_pack
-%type type_decl
-%type var_type_decl
-%type predefined_type
-%type full_type
-%type anonymous_struct
-%type named_struct
-%type enum
-%type enum_keyword
-%type struct_keyword
-%type simple_type
-%type simple_int_type
-%type simple_float_type
-%type simple_void_type
-%type class_derivation_name
-%type enum_element_type
-%type maybe_trailing_return_type
-%type maybe_comma_identifier
-/*%type typedefname*/
-%type name
-%type name_no_final
-%type string_literal
-
-/* We need to treat KW_OPERATOR as a scopable keyword. */
-%type KW_OPERATOR
-
-%type optional_const_expr
-%type optional_const_expr_comma
-%type const_expr_comma
-%type no_angle_bracket_const_expr
-%type const_expr
-%type const_operand
-%type formal_const_expr
-%type formal_const_operand
-
-
-/* Precedence rules. */
-
-%left IDENTIFIER TYPENAME_IDENTIFIER TYPEDEFNAME KW_ENUM ELLIPSIS KW_OPERATOR KW_TYPENAME KW_INT KW_SHORT KW_UNSIGNED KW_SIGNED KW_LONG KW_FLOAT KW_DOUBLE KW_CHAR KW_WCHAR_T KW_CHAR8_T KW_CHAR16_T KW_CHAR32_T KW_BOOL
-
-%left '{' ',' ';'
-
-%nonassoc KW_THROW
-%right ':'
-%right '='
-%right '?'
-%left OROR
-%left ANDAND
-%left '|'
-%left '^'
-%left '&'
-%left EQCOMPARE NECOMPARE
-%left LECOMPARE GECOMPARE '<' '>'
-%left SPACESHIP
-%left LSHIFT RSHIFT
-%left '+' '-'
-%left '*' '/' '%'
-%left POINTSAT_STAR DOT_STAR
-%right UNARY PLUSPLUS MINUSMINUS '~'
-%left POINTSAT '.' '(' '['
-
-%right SCOPE
-%nonassoc KW_NEW KW_DELETE KW_TRY KW_CATCH
-
-%%
-
-grammar:
- START_CPP cpp
- | START_CONST_EXPR const_expr
-{
- current_expr = $2;
-}
- | START_TYPE full_type
-{
- current_type = $2;
-}
- ;
-
-cpp:
- empty
- | cpp optional_attributes ';'
-{
- if (!$2.is_empty()) {
- current_scope->add_declaration(new CPPDeclaration(@2.file, $2), global_scope, current_lexer, @2);
- }
-}
- | cpp optional_attributes
-{
- current_attributes = $2;
-}
- declaration
-{
- current_attributes = CPPAttributeList();
-}
- ;
-
-constructor_inits:
- constructor_init
- | constructor_inits ',' constructor_init
- ;
-
-constructor_init:
- name '(' optional_const_expr_comma ')'
-{
- delete $3;
-}
- | name '(' optional_const_expr_comma ')' ELLIPSIS
-{
- delete $3;
-}
- | name '{' optional_const_expr_comma '}'
-{
- delete $3;
-}
- ;
-
-/* This is principally for the syntax: extern "C" { ... }.
-
- We use storage_class instead of simply KW_EXTERN to avoid
- shift/reduce conflicts with yacc's limited differentiation
- ability. */
-extern_c:
- storage_class '{'
-{
- push_storage_class((current_storage_class & ~CPPInstance::SC_c_binding) |
- ($1 & CPPInstance::SC_c_binding));
-}
- cpp '}'
-{
- pop_storage_class();
-}
- ;
-
-declaration:
- type_like_declaration
- | template_declaration
- | extern_c
- | namespace_declaration
- | friend_declaration
- | KW_TYPEDEF typedef_declaration
- | KW_BEGIN_PUBLISH
-{
- if (publish_nest_level != 0) {
- yyerror("Unclosed __begin_publish", publish_loc);
- publish_nest_level = 0;
- current_scope->set_current_vis(V_public);
- }
-
- publish_previous = current_scope->get_current_vis();
- publish_loc = @1;
- publish_nest_level++;
- current_scope->set_current_vis(V_published);
-}
- | KW_END_PUBLISH
-{
- if (publish_nest_level != 1) {
- yyerror("Unmatched __end_publish", @1);
- } else {
- current_scope->set_current_vis(publish_previous);
- }
- publish_nest_level = 0;
-}
- | KW_PUBLISHED ':'
-{
- current_scope->set_current_vis(V_published);
-}
- | KW_PUBLIC ':'
-{
- if (publish_nest_level > 0) {
- current_scope->set_current_vis(V_published);
- } else {
- current_scope->set_current_vis(V_public);
- }
-}
- | KW_PROTECTED ':'
-{
- current_scope->set_current_vis(V_protected);
-}
- | KW_PRIVATE ':'
-{
- current_scope->set_current_vis(V_private);
-}
- | KW_MAKE_PROPERTY '(' name ',' IDENTIFIER maybe_comma_identifier ')' ';'
-{
- CPPDeclaration *getter = $5->find_symbol(current_scope, global_scope, current_lexer);
- if (getter == nullptr || getter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("Reference to non-existent or invalid getter: " + $5->get_fully_scoped_name(), @5);
- } else {
- CPPMakeProperty *make_property = new CPPMakeProperty($3, CPPMakeProperty::T_normal, current_scope, @1.file);
- make_property->_get_function = getter->as_function_group();
-
- if ($6 != nullptr) {
- CPPDeclaration *setter = $6->find_symbol(current_scope, global_scope, current_lexer);
- if (setter == nullptr || setter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("Reference to non-existent or invalid setter: " + $6->get_fully_scoped_name(), @6);
- } else {
- make_property->_set_function = setter->as_function_group();
- }
- }
-
- current_scope->add_declaration(make_property, global_scope, current_lexer, @1);
- }
-}
- | KW_MAKE_PROPERTY '(' name ',' IDENTIFIER ',' IDENTIFIER ',' IDENTIFIER ')' ';'
-{
- CPPDeclaration *getter = $5->find_symbol(current_scope, global_scope, current_lexer);
- if (getter == nullptr || getter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("Reference to non-existent or invalid getter: " + $5->get_fully_scoped_name(), @5);
-
- } else {
- CPPMakeProperty *make_property = new CPPMakeProperty($3, CPPMakeProperty::T_normal, current_scope, @1.file);
- make_property->_get_function = getter->as_function_group();
-
- CPPDeclaration *setter = $7->find_symbol(current_scope, global_scope, current_lexer);
- if (setter == nullptr || setter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("Reference to non-existent or invalid setter: " + $7->get_fully_scoped_name(), @7);
- } else {
- make_property->_set_function = setter->as_function_group();
- }
-
- CPPDeclaration *deleter = $9->find_symbol(current_scope, global_scope, current_lexer);
- if (deleter == nullptr || deleter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("reference to non-existent or invalid delete method: " + $9->get_fully_scoped_name(), @9);
- } else {
- make_property->_del_function = deleter->as_function_group();
- }
-
- current_scope->add_declaration(make_property, global_scope, current_lexer, @1);
- }
-}
- | KW_MAKE_SEQ_PROPERTY '(' name ',' IDENTIFIER ',' IDENTIFIER ')' ';'
-{
- CPPDeclaration *length_getter = $5->find_symbol(current_scope, global_scope, current_lexer);
- if (length_getter == nullptr || length_getter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("reference to non-existent or invalid length method: " + $5->get_fully_scoped_name(), @5);
- length_getter = nullptr;
- }
-
- CPPDeclaration *getter = $7->find_symbol(current_scope, global_scope, current_lexer);
- if (getter == nullptr || getter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("Reference to non-existent or invalid getter: " + $7->get_fully_scoped_name(), @7);
- getter = nullptr;
- }
-
- if (getter != nullptr && length_getter != nullptr) {
- CPPMakeProperty *make_property = new CPPMakeProperty($3, CPPMakeProperty::T_sequence, current_scope, @1.file);
- make_property->_get_function = getter->as_function_group();
- make_property->_length_function = length_getter->as_function_group();
- current_scope->add_declaration(make_property, global_scope, current_lexer, @1);
- }
-}
- | KW_MAKE_SEQ_PROPERTY '(' name ',' IDENTIFIER ',' IDENTIFIER ',' IDENTIFIER ')' ';'
-{
- CPPDeclaration *length_getter = $5->find_symbol(current_scope, global_scope, current_lexer);
- if (length_getter == nullptr || length_getter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("reference to non-existent or invalid length method: " + $5->get_fully_scoped_name(), @5);
- length_getter = nullptr;
- }
-
- CPPDeclaration *getter = $7->find_symbol(current_scope, global_scope, current_lexer);
- if (getter == nullptr || getter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("Reference to non-existent or invalid getter: " + $7->get_fully_scoped_name(), @7);
- getter = nullptr;
- }
-
- if (getter != nullptr && length_getter != nullptr) {
- CPPMakeProperty *make_property = new CPPMakeProperty($3, CPPMakeProperty::T_sequence, current_scope, @1.file);
- make_property->_get_function = getter->as_function_group();
- make_property->_length_function = length_getter->as_function_group();
-
- CPPDeclaration *setter = $9->find_symbol(current_scope, global_scope, current_lexer);
- if (setter == nullptr || setter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("Reference to non-existent or invalid setter: " + $9->get_fully_scoped_name(), @9);
- } else {
- make_property->_set_function = setter->as_function_group();
- }
-
- current_scope->add_declaration(make_property, global_scope, current_lexer, @1);
- }
-}
- | KW_MAKE_SEQ_PROPERTY '(' name ',' IDENTIFIER ',' IDENTIFIER ',' IDENTIFIER ',' IDENTIFIER ')' ';'
-{
- CPPDeclaration *length_getter = $5->find_symbol(current_scope, global_scope, current_lexer);
- if (length_getter == nullptr || length_getter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("reference to non-existent or invalid length method: " + $5->get_fully_scoped_name(), @5);
- length_getter = nullptr;
- }
-
- CPPDeclaration *getter = $7->find_symbol(current_scope, global_scope, current_lexer);
- if (getter == nullptr || getter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("Reference to non-existent or invalid getter: " + $7->get_fully_scoped_name(), @7);
- getter = nullptr;
- }
-
- if (getter != nullptr && length_getter != nullptr) {
- CPPMakeProperty *make_property = new CPPMakeProperty($3, CPPMakeProperty::T_sequence, current_scope, @1.file);
- make_property->_get_function = getter->as_function_group();
- make_property->_length_function = length_getter->as_function_group();
-
- CPPDeclaration *setter = $9->find_symbol(current_scope, global_scope, current_lexer);
- if (setter == nullptr || setter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("Reference to non-existent or invalid setter: " + $9->get_fully_scoped_name(), @9);
- } else {
- make_property->_set_function = setter->as_function_group();
- }
-
- CPPDeclaration *deleter = $11->find_symbol(current_scope, global_scope, current_lexer);
- if (deleter == nullptr || deleter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("reference to non-existent or invalid delete method: " + $11->get_fully_scoped_name(), @11);
- } else {
- make_property->_del_function = deleter->as_function_group();
- }
-
- current_scope->add_declaration(make_property, global_scope, current_lexer, @1);
- }
-}
- | KW_MAKE_SEQ_PROPERTY '(' name ',' IDENTIFIER ',' IDENTIFIER ',' IDENTIFIER ',' IDENTIFIER ',' IDENTIFIER ')' ';'
-{
- CPPDeclaration *length_getter = $5->find_symbol(current_scope, global_scope, current_lexer);
- if (length_getter == nullptr || length_getter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("reference to non-existent or invalid length method: " + $5->get_fully_scoped_name(), @5);
- length_getter = nullptr;
- }
-
- CPPDeclaration *getter = $7->find_symbol(current_scope, global_scope, current_lexer);
- if (getter == nullptr || getter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("Reference to non-existent or invalid getter: " + $7->get_fully_scoped_name(), @7);
- getter = nullptr;
- }
-
- if (getter != nullptr && length_getter != nullptr) {
- CPPMakeProperty *make_property = new CPPMakeProperty($3, CPPMakeProperty::T_sequence, current_scope, @1.file);
- make_property->_get_function = getter->as_function_group();
- make_property->_length_function = length_getter->as_function_group();
-
- CPPDeclaration *setter = $9->find_symbol(current_scope, global_scope, current_lexer);
- if (setter == nullptr || setter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("Reference to non-existent or invalid setter: " + $9->get_fully_scoped_name(), @9);
- } else {
- make_property->_set_function = setter->as_function_group();
- }
-
- CPPDeclaration *deleter = $11->find_symbol(current_scope, global_scope, current_lexer);
- if (deleter == nullptr || deleter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("reference to non-existent or invalid delete method: " + $11->get_fully_scoped_name(), @11);
- } else {
- make_property->_del_function = deleter->as_function_group();
- }
-
- CPPDeclaration *inserter = $13->find_symbol(current_scope, global_scope, current_lexer);
- if (inserter == nullptr || inserter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("reference to non-existent or invalid append method: " + $13->get_fully_scoped_name(), @13);
- } else {
- make_property->_insert_function = inserter->as_function_group();
- }
-
- current_scope->add_declaration(make_property, global_scope, current_lexer, @1);
- }
-}
- | KW_MAKE_MAP_PROPERTY '(' name ',' IDENTIFIER ')' ';'
-{
- CPPDeclaration *getter = $5->find_symbol(current_scope, global_scope, current_lexer);
- if (getter == nullptr || getter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("reference to non-existent or invalid item getter method: " + $5->get_fully_scoped_name(), @5);
-
- } else {
- CPPMakeProperty *make_property = new CPPMakeProperty($3, CPPMakeProperty::T_mapping, current_scope, @1.file);
- make_property->_get_function = getter->as_function_group();
- current_scope->add_declaration(make_property, global_scope, current_lexer, @1);
- }
-}
- | KW_MAKE_MAP_PROPERTY '(' name ',' IDENTIFIER ',' IDENTIFIER ')' ';'
-{
- CPPDeclaration *getter = $7->find_symbol(current_scope, global_scope, current_lexer);
- if (getter == nullptr || getter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("Reference to non-existent or invalid getter: " + $7->get_fully_scoped_name(), @7);
-
- } else {
- CPPMakeProperty *make_property;
- make_property = new CPPMakeProperty($3, CPPMakeProperty::T_mapping, current_scope, @1.file);
- make_property->_get_function = getter->as_function_group();
-
- CPPDeclaration *hasser = $5->find_symbol(current_scope, global_scope, current_lexer);
- if (hasser == nullptr || hasser->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("reference to non-existent or invalid has/find method: " + $5->get_fully_scoped_name(), @5);
- } else {
- make_property->_has_function = hasser->as_function_group();
- }
-
- current_scope->add_declaration(make_property, global_scope, current_lexer, @1);
- }
-}
- | KW_MAKE_MAP_PROPERTY '(' name ',' IDENTIFIER ',' IDENTIFIER ',' IDENTIFIER maybe_comma_identifier ')' ';'
-{
- CPPDeclaration *getter = $7->find_symbol(current_scope, global_scope, current_lexer);
- if (getter == nullptr || getter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("Reference to non-existent or invalid getter: " + $7->get_fully_scoped_name(), @7);
-
- } else {
- CPPMakeProperty *make_property = new CPPMakeProperty($3, CPPMakeProperty::T_mapping, current_scope, @1.file);
- make_property->_get_function = getter->as_function_group();
-
- CPPDeclaration *hasser = $5->find_symbol(current_scope, global_scope, current_lexer);
- if (hasser == nullptr || hasser->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("reference to non-existent or invalid has/find method: " + $5->get_fully_scoped_name(), @5);
- } else {
- make_property->_has_function = hasser->as_function_group();
- }
-
- CPPDeclaration *setter = $9->find_symbol(current_scope, global_scope, current_lexer);
- if (setter == nullptr || setter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("Reference to non-existent or invalid setter: " + $9->get_fully_scoped_name(), @9);
- } else {
- make_property->_set_function = setter->as_function_group();
- }
-
- if ($10 != nullptr) {
- CPPDeclaration *deleter = $10->find_symbol(current_scope, global_scope, current_lexer);
- if (deleter == nullptr || deleter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("reference to non-existent or invalid delete method: " + $10->get_fully_scoped_name(), @10);
- } else {
- make_property->_del_function = deleter->as_function_group();
- }
- }
-
- current_scope->add_declaration(make_property, global_scope, current_lexer, @1);
- }
-}
- | KW_MAKE_MAP_KEYS_SEQ '(' name ',' IDENTIFIER ',' IDENTIFIER ')' ';'
-{
- CPPDeclaration *length_getter = $5->find_symbol(current_scope, global_scope, current_lexer);
- if (length_getter == nullptr || length_getter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("reference to non-existent or invalid length method: " + $5->get_fully_scoped_name(), @5);
- length_getter = nullptr;
- }
-
- CPPDeclaration *getter = $7->find_symbol(current_scope, global_scope, current_lexer);
- if (getter == nullptr || getter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("reference to non-existent or invalid getter: " + $7->get_fully_scoped_name(), @7);
- getter = nullptr;
- }
-
- if (getter != nullptr && length_getter != nullptr) {
- CPPMakeProperty *make_property = nullptr;
- for (size_t i = 0; i < current_scope->_declarations.size(); ++i) {
- make_property = current_scope->_declarations[i]->as_make_property();
- if (make_property != nullptr) {
- if (make_property->get_fully_scoped_name() == $3->get_fully_scoped_name()) {
- break;
- } else {
- make_property = nullptr;
- }
- }
- }
- if (make_property != nullptr) {
- make_property->_get_key_function = getter->as_function_group();
- make_property->_length_function = length_getter->as_function_group();
- } else {
- yyerror("reference to non-existent MAKE_MAP_PROPERTY: " + $3->get_fully_scoped_name(), @3);
- }
- }
-}
- | KW_MAKE_PROPERTY2 '(' name ',' IDENTIFIER ',' IDENTIFIER ')' ';'
-{
- CPPDeclaration *getter = $7->find_symbol(current_scope, global_scope, current_lexer);
- if (getter == nullptr || getter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("Reference to non-existent or invalid getter: " + $7->get_fully_scoped_name(), @7);
-
- } else {
- CPPMakeProperty *make_property;
- make_property = new CPPMakeProperty($3, CPPMakeProperty::T_normal,
- current_scope, @1.file);
- make_property->_get_function = getter->as_function_group();
-
- CPPDeclaration *hasser = $5->find_symbol(current_scope, global_scope, current_lexer);
- if (hasser == nullptr || hasser->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("reference to non-existent or invalid has/find method: " + $5->get_fully_scoped_name(), @5);
- } else {
- make_property->_has_function = hasser->as_function_group();
- }
-
- current_scope->add_declaration(make_property, global_scope, current_lexer, @1);
- }
-}
- | KW_MAKE_PROPERTY2 '(' name ',' IDENTIFIER ',' IDENTIFIER ',' IDENTIFIER ',' IDENTIFIER ')' ';'
-{
- CPPDeclaration *getter = $7->find_symbol(current_scope, global_scope, current_lexer);
- if (getter == nullptr || getter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("Reference to non-existent or invalid getter: " + $7->get_fully_scoped_name(), @7);
-
- } else {
- CPPMakeProperty *make_property;
- make_property = new CPPMakeProperty($3, CPPMakeProperty::T_normal,
- current_scope, @1.file);
- make_property->_get_function = getter->as_function_group();
-
- CPPDeclaration *hasser = $5->find_symbol(current_scope, global_scope, current_lexer);
- if (hasser == nullptr || hasser->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("reference to non-existent or invalid has/find method: " + $5->get_fully_scoped_name(), @5);
- } else {
- make_property->_has_function = hasser->as_function_group();
- }
-
- CPPDeclaration *setter = $9->find_symbol(current_scope, global_scope, current_lexer);
- if (setter == nullptr || setter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("reference to non-existent or invalid setter: " + $9->get_fully_scoped_name(), @9);
- } else {
- make_property->_set_function = setter->as_function_group();
- }
-
- CPPDeclaration *clearer = $11->find_symbol(current_scope, global_scope, current_lexer);
- if (clearer == nullptr || clearer->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("reference to non-existent or invalid clear method: " + $11->get_fully_scoped_name(), @11);
- } else {
- make_property->_clear_function = clearer->as_function_group();
- }
-
- current_scope->add_declaration(make_property, global_scope, current_lexer, @1);
- }
-}
- | KW_MAKE_SEQ '(' name ',' IDENTIFIER ',' IDENTIFIER ')' ';'
-{
- CPPDeclaration *length_getter = $5->find_symbol(current_scope, global_scope, current_lexer);
- if (length_getter == nullptr || length_getter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("reference to non-existent or invalid length method: " + $5->get_fully_scoped_name(), @5);
- length_getter = nullptr;
- }
-
- CPPDeclaration *element_getter = $7->find_symbol(current_scope, global_scope, current_lexer);
- if (element_getter == nullptr || element_getter->get_subtype() != CPPDeclaration::ST_function_group) {
- yyerror("reference to non-existent or invalid element method: " + $7->get_fully_scoped_name(), @5);
- element_getter = nullptr;
- }
-
- if (length_getter != nullptr && element_getter != nullptr) {
- CPPMakeSeq *make_seq = new CPPMakeSeq($3,
- length_getter->as_function_group(),
- element_getter->as_function_group(),
- current_scope, @1.file);
- current_scope->add_declaration(make_seq, global_scope, current_lexer, @1);
- }
-}
- | KW_STATIC_ASSERT '(' const_expr ',' string_literal ')' ';'
-{
- CPPExpression::Result result = $3->evaluate();
- if (result._type == CPPExpression::RT_error) {
- yywarning("static_assert requires a constant expression", @3);
- } else if (!result.as_boolean()) {
- stringstream str;
- str << *$5;
- yywarning("static_assert failed: " + str.str(), @3);
- }
-}
- | KW_STATIC_ASSERT '(' const_expr ')' ';'
-{
- // This alternative version of static_assert was introduced in C++17.
- CPPExpression::Result result = $3->evaluate();
- if (result._type == CPPExpression::RT_error) {
- yywarning("static_assert requires a constant expression", @3);
- } else if (!result.as_boolean()) {
- yywarning("static_assert failed", @3);
- }
-}
- ;
-
-friend_declaration:
- KW_FRIEND
-{
- CPPScope *new_scope = new CPPScope(current_scope, CPPNameComponent("temp"),
- V_public);
- push_scope(new_scope);
-}
- declaration
-{
- delete current_scope;
- pop_scope();
-}
- ;
-
-
-storage_class:
- empty
-{
- $$ = 0;
-}
- | KW_CONST storage_class
-{
- // This isn't really a storage class, but it helps with parsing.
- $$ = $2 | (int)CPPInstance::SC_const;
-}
- | KW_EXTERN storage_class
-{
- $$ = $2 | (int)CPPInstance::SC_extern;
-}
- | KW_EXTERN SIMPLE_STRING storage_class
-{
- $$ = $3 | (int)CPPInstance::SC_extern;
- if ($2 == "C") {
- $$ |= (int)CPPInstance::SC_c_binding;
- } else if ($2 == "C++") {
- $$ &= ~(int)CPPInstance::SC_c_binding;
- } else {
- yywarning("Ignoring unknown linkage type \"" + $2 + "\"", @2);
- }
-}
- | KW_STATIC storage_class
-{
- $$ = $2 | (int)CPPInstance::SC_static;
-}
- | KW_INLINE storage_class
-{
- $$ = $2 | (int)CPPInstance::SC_inline;
-}
- | KW_VIRTUAL storage_class
-{
- $$ = $2 | (int)CPPInstance::SC_virtual;
-}
- | KW_EXPLICIT storage_class
-{
- $$ = $2 | (int)CPPInstance::SC_explicit;
-}
- | KW_EXPLICIT_LPAREN const_expr ')' storage_class
-{
- CPPExpression::Result result = $2->evaluate();
- if (result._type == CPPExpression::RT_error) {
- yywarning("explicit() requires a constant expression", @2);
- } else if (result.as_boolean()) {
- $$ = $4 | (int)CPPInstance::SC_explicit;
- }
-}
- | KW_REGISTER storage_class
-{
- $$ = $2 | (int)CPPInstance::SC_register;
-}
- | KW_VOLATILE storage_class
-{
- $$ = $2 | (int)CPPInstance::SC_volatile;
-}
- | KW_MUTABLE storage_class
-{
- $$ = $2 | (int)CPPInstance::SC_mutable;
-}
- | KW_CONSTEVAL storage_class
-{
- $$ = $2 | (int)CPPInstance::SC_consteval;
-}
- | KW_CONSTEXPR storage_class
-{
- $$ = $2 | (int)CPPInstance::SC_constexpr;
-}
- | KW_CONSTINIT storage_class
-{
- $$ = $2 | (int)CPPInstance::SC_constinit;
-}
- | KW_BLOCKING storage_class
-{
- $$ = $2 | (int)CPPInstance::SC_blocking;
-}
- | KW_EXTENSION storage_class
-{
- $$ = $2 | (int)CPPInstance::SC_extension;
-}
- | KW_THREAD_LOCAL storage_class
-{
- $$ = $2 | (int)CPPInstance::SC_thread_local;
-}
- ;
-
-optional_attributes:
- empty
-{
- $$ = CPPAttributeList();
-}
- | ATTR_LEFT attribute_specifiers ATTR_RIGHT optional_attributes
-{
- $$ = $2;
- $$.add_attributes_from($4);
-}
- | ATTR_LEFT KW_USING name ':' attribute_specifiers ATTR_RIGHT optional_attributes
-{
- $$ = $5;
- for (CPPAttributeList::Attribute &attr : $$._attributes) {
- attr._ident->prepend($3);
- }
- $$.add_attributes_from($7);
-}
- | KW_ALIGNAS '(' const_expr ')' optional_attributes
-{
- $$ = $5;
- $$.add_alignas($3->as_expression());
-}
- | KW_ALIGNAS '(' type_decl ')' optional_attributes
-{
- $$ = $5;
- $$.add_alignas($3->as_type());
-}
- ;
-
-attribute_specifiers:
- attribute_specifier
-{
- $$ = $1;
-}
- | attribute_specifier ',' attribute_specifiers
-{
- $$ = $1;
- $$.add_attributes_from($3);
-}
- ;
-
-attribute_specifier:
- name
-{
- $$ = CPPAttributeList();
- $$.add_attribute($1);
-}
- | name '(' formal_parameter_list ')'
-{
- $$ = CPPAttributeList();
- $$.add_attribute($1);
-}
- ;
-
-type_like_declaration:
- storage_class var_type_decl
-{
- // We don't need to push/pop type, because we can't nest
- // type_like_declaration.
- if ($2->as_type_declaration()) {
- current_type = $2->as_type_declaration()->_type;
- } else {
- current_type = $2->as_type();
- }
- push_storage_class($1);
-}
- multiple_instance_identifiers
-{
- pop_storage_class();
-}
-
- | storage_class type_decl ';'
-{
- // We don't really care about the storage class here. In fact, it's
- // not actually legal to define a class or struct using a particular
- // storage class, but we require it just to help yacc out in its
- // parsing.
-
- current_scope->add_declaration($2, global_scope, current_lexer, @2);
-}
- | storage_class constructor_prototype
-{
- if ($2 != nullptr) {
- // Push the scope so that the initializers can make use of things defined
- // in the class body.
- push_scope($2->get_scope(current_scope, global_scope));
- $2->_storage_class |= (current_storage_class | $1);
- }
-}
- maybe_initialize_or_constructor_body
-{
- if ($2 != nullptr) {
- pop_scope();
- current_scope->add_declaration($2, global_scope, current_lexer, @2);
- $2->set_initializer($4);
- }
-}
- | storage_class function_prototype maybe_initialize_or_function_body
-{
- if ($2 != nullptr) {
- $2->_storage_class |= (current_storage_class | $1);
- current_scope->add_declaration($2, global_scope, current_lexer, @2);
- $2->set_initializer($3);
- }
-}
- | using_declaration
-
- /* We don't need to include a rule for variables that point to
- functions, because we get those from the function_prototype
- definition. */
- ;
-
-multiple_instance_identifiers:
- instance_identifier_and_maybe_trailing_return_type maybe_initialize_or_function_body
-{
- if (current_storage_class & CPPInstance::SC_const) {
- $1->add_modifier(IIT_const);
- }
- $1->add_attributes(current_attributes);
- CPPInstance *inst = new CPPInstance(current_type, $1,
- current_storage_class,
- @1.file);
- inst->set_initializer($2);
- current_scope->add_declaration(inst, global_scope, current_lexer, @1);
-}
- | instance_identifier_and_maybe_trailing_return_type maybe_initialize ',' multiple_instance_identifiers
-{
- if (current_storage_class & CPPInstance::SC_const) {
- $1->add_modifier(IIT_const);
- }
- $1->add_attributes(current_attributes);
- CPPInstance *inst = new CPPInstance(current_type, $1,
- current_storage_class,
- @1.file);
- inst->set_initializer($2);
- current_scope->add_declaration(inst, global_scope, current_lexer, @1);
-}
- ;
-
-
-typedef_declaration:
- storage_class var_type_decl
-{
- // We don't need to push/pop type, because we can't nest
- // multiple_var_declarations.
- if ($2->as_type_declaration()) {
- current_type = $2->as_type_declaration()->_type;
- } else {
- current_type = $2->as_type();
- }
- push_storage_class($1);
-}
- typedef_instance_identifiers
-{
- pop_storage_class();
-}
- | storage_class function_prototype maybe_initialize_or_function_body
-{
- if ($2 != nullptr) {
- CPPInstance *inst = $2->as_instance();
- if (inst != nullptr) {
- inst->_storage_class |= (current_storage_class | $1);
- current_scope->add_declaration(inst, global_scope, current_lexer, @2);
- CPPTypedefType *typedef_type = new CPPTypedefType(inst->_type, inst->_ident, current_scope, inst->_attributes);
- current_scope->add_declaration(CPPType::new_type(typedef_type), global_scope, current_lexer, @2);
- }
- }
-}
- ;
-
-typedef_instance_identifiers:
- instance_identifier_and_maybe_trailing_return_type maybe_initialize_or_function_body
-{
- if (current_storage_class & CPPInstance::SC_const) {
- $1->add_modifier(IIT_const);
- }
- $1->add_attributes(current_attributes);
- CPPType *target_type = current_type;
- CPPTypedefType *typedef_type = new CPPTypedefType(target_type, $1, current_scope, @1.file);
- current_scope->add_declaration(CPPType::new_type(typedef_type), global_scope, current_lexer, @1);
-}
- | instance_identifier_and_maybe_trailing_return_type maybe_initialize ',' typedef_instance_identifiers
-{
- if (current_storage_class & CPPInstance::SC_const) {
- $1->add_modifier(IIT_const);
- }
- $1->add_attributes(current_attributes);
- CPPType *target_type = current_type;
- CPPTypedefType *typedef_type = new CPPTypedefType(target_type, $1, current_scope, @1.file);
- current_scope->add_declaration(CPPType::new_type(typedef_type), global_scope, current_lexer, @1);
-}
- ;
-
-constructor_prototype:
-
-/* Functions with implicit return types, and constructors */
- IDENTIFIER '('
-{
- // Create a scope for this function.
- CPPScope *scope = new CPPScope($1->get_scope(current_scope, global_scope),
- $1->_names.back(), V_private);
-
- // It still needs to be able to pick up any template arguments, if this is
- // a definition for a method template. Add a fake "using" declaration to
- // accomplish this.
- scope->_using.insert(current_scope);
-
- push_scope(scope);
-}
- function_parameter_list ')' function_post optional_attributes
-{
- CPPScope *scope = $1->get_scope(current_scope, global_scope);
- CPPType *type;
- std::string simple_name = $1->get_simple_name();
- if (!simple_name.empty() && simple_name[0] == '~') {
- // A destructor has no return type.
- type = new CPPSimpleType(CPPSimpleType::T_void);
- }
- else if (scope != nullptr && simple_name == scope->get_simple_name()) {
- // Neither does a constructor.
- type = new CPPSimpleType(CPPSimpleType::T_void);
- }
- else {
- // This isn't a constructor, so it has an implicit return type of
- // int.
- yywarning("function has no return type, assuming int", @1);
- type = new CPPSimpleType(CPPSimpleType::T_int);
- }
- pop_scope();
-
- CPPInstanceIdentifier *ii = new CPPInstanceIdentifier($1);
- ii->add_func_modifier($4, $6, nullptr, $7);
- ii->add_attributes(current_attributes);
-
- $$ = new CPPInstance(type, ii, 0, @1.file);
-}
-/* This is a hack to support functions with the identifier enveloped by a
- pair of parentheses. */
- | TYPENAME_IDENTIFIER '(' IDENTIFIER ')' '('
-{
- // Create a scope for this function.
- CPPScope *scope = new CPPScope($3->get_scope(current_scope, global_scope),
- $3->_names.back(), V_private);
-
- // It still needs to be able to pick up any template arguments, if this is
- // a definition for a method template. Add a fake "using" declaration to
- // accomplish this.
- scope->_using.insert(current_scope);
-
- push_scope(scope);
-}
- function_parameter_list ')' function_post optional_attributes
-{
- pop_scope();
- CPPType *type = $1->find_type(current_scope, global_scope, false, current_lexer);
- if (type == nullptr) {
- yyerror(string("internal error resolving type ") + $1->get_fully_scoped_name(), @1);
- }
- assert(type != nullptr);
-
- CPPInstanceIdentifier *ii = new CPPInstanceIdentifier($3);
- ii->add_func_modifier($7, $9, nullptr, $10);
- ii->add_attributes(current_attributes);
-
- $$ = new CPPInstance(type, ii, 0, @1.file);
-}
- | TYPENAME_IDENTIFIER '('
-{
- // Create a scope for this function.
- CPPScope *scope = new CPPScope($1->get_scope(current_scope, global_scope),
- $1->_names.back(), V_private);
-
- // It still needs to be able to pick up any template arguments, if this is
- // a definition for a method template. Add a fake "using" declaration to
- // accomplish this.
- scope->_using.insert(current_scope);
-
- push_scope(scope);
-}
- function_parameter_list ')' function_post optional_attributes
-{
- pop_scope();
- CPPType *type;
- if ($1->get_simple_name() == current_scope->get_simple_name()) {
- // This is a constructor, and has no return.
- type = new CPPSimpleType(CPPSimpleType::T_void);
- } else {
- // This isn't a constructor, so it has an implicit return type of
- // int.
- type = new CPPSimpleType(CPPSimpleType::T_int);
- }
-
- CPPInstanceIdentifier *ii = new CPPInstanceIdentifier($1);
- ii->add_func_modifier($4, $6, nullptr, $7);
- ii->add_attributes(current_attributes);
-
- $$ = new CPPInstance(type, ii, 0, @1.file);
-}
- ;
-
-function_prototype:
-
-/* Destructors */
- '~' name '('
-{
- push_scope($2->get_scope(current_scope, global_scope));
-}
- function_parameter_list ')' function_post optional_attributes
-{
- pop_scope();
- if ($2->is_scoped()) {
- yyerror("Invalid destructor name: ~" + $2->get_fully_scoped_name(), @2);
- } else {
- CPPIdentifier *ident =
- new CPPIdentifier("~" + $2->get_simple_name(), @2);
- delete $2;
-
- CPPType *type;
- type = new CPPSimpleType(CPPSimpleType::T_void);
-
- CPPInstanceIdentifier *ii = new CPPInstanceIdentifier(ident);
- ii->add_func_modifier($5, $7, nullptr, $8);
- ii->add_attributes(current_attributes);
-
- $$ = new CPPInstance(type, ii, 0, @2.file);
- }
-}
-
-/* This is a special case: a function pointer declaration that looks
- at first a lot like a constructor declaration. This is provided to
- help yacc sort out the differences. It isn't an ideal solution,
- because it doesn't catch a lot of subtle variants on this form--but
- this will get at least the 99% most common uses. */
-
- | TYPENAME_IDENTIFIER '(' '*' instance_identifier ')' '('
-{
- push_scope($4->get_scope(current_scope, global_scope));
-}
- function_parameter_list ')' function_post optional_attributes maybe_trailing_return_type
-{
- pop_scope();
- CPPType *type = $1->find_type(current_scope, global_scope, false, current_lexer);
- if (type == nullptr) {
- yyerror(string("internal error resolving type ") + $1->get_fully_scoped_name(), @1);
- }
- assert(type != nullptr);
-
- CPPInstanceIdentifier *ii = $4;
- ii->add_modifier(IIT_pointer);
- ii->add_func_modifier($8, $10, nullptr, $11);
- ii->add_attributes(current_attributes);
- $$ = new CPPInstance(type, ii, 0, @1.file);
-}
- | TYPENAME_IDENTIFIER '(' SCOPING '*' instance_identifier ')' '('
-{
- push_scope($5->get_scope(current_scope, global_scope));
-}
- function_parameter_list ')' function_post optional_attributes maybe_trailing_return_type
-{
- pop_scope();
- CPPType *type = $1->find_type(current_scope, global_scope, false, current_lexer);
- if (type == nullptr) {
- yyerror(string("internal error resolving type ") + $1->get_fully_scoped_name(), @1);
- }
- assert(type != nullptr);
-
- CPPInstanceIdentifier *ii = $5;
- ii->add_scoped_pointer_modifier($3);
- ii->add_func_modifier($9, $11, nullptr, $12);
- ii->add_attributes(current_attributes);
- $$ = new CPPInstance(type, ii, 0, @1.file);
-}
-
-/* Typecast operators */
- | KW_OPERATOR type not_paren_formal_parameter_identifier '('
-{
- if ($1 != nullptr) {
- push_scope($1->get_scope(current_scope, global_scope));
- }
-}
- function_parameter_list ')' function_post
-{
- if ($1 != nullptr) {
- pop_scope();
- }
-
- // We use formal_parameter_identifier, because that can match a type
- // name with or without an identifier, but especially without, which
- // is what follows the keyword "operator" in a typecast function.
- // As an added bonus, the type of the formal_parameter will be the
- // typecast type, i.e. the return type of the typecast function.
-
- // We give typecast operators the name "operator typecast ",
- // where is a simple name of the type to be typecast. Use
- // the method's return type to determine the full type description.
- string name = "operator typecast " + $2->get_simple_name();
- CPPIdentifier *ident = $1;
- if (ident == nullptr) {
- ident = new CPPIdentifier(name, @2);
- } else {
- ident->add_name(name);
- }
- $$ = CPPInstance::make_typecast_function
- (new CPPInstance($2, $3, 0, @3.file), ident, $6, $8);
- $$->_attributes.add_attributes_from(current_attributes);
-}
- | KW_OPERATOR KW_CONST type not_paren_formal_parameter_identifier '('
-{
- if ($1 != nullptr) {
- push_scope($1->get_scope(current_scope, global_scope));
- }
-}
- function_parameter_list ')' function_post
-{
- if ($1 != nullptr) {
- pop_scope();
- }
-
- CPPIdentifier *ident = $1;
- if (ident == nullptr) {
- ident = new CPPIdentifier("operator typecast", @4);
- } else {
- ident->add_name("operator typecast");
- }
- $4->add_modifier(IIT_const);
- $4->add_attributes(current_attributes);
- $$ = CPPInstance::make_typecast_function
- (new CPPInstance($3, $4, 0, @4.file), ident, $7, $9);
-}
-
-/* Not actually a function prototype, but maybe a template
- instantiation. Just included here (instead of somewhere else) to
- avoid shift/reduce conflicts. */
- | IDENTIFIER
-{
- CPPDeclaration *decl =
- $1->find_symbol(current_scope, global_scope, current_lexer);
- if (decl != nullptr) {
- $$ = decl->as_instance();
- } else {
- $$ = nullptr;
- }
-}
- ;
-
-function_post:
- empty
-{
- $$ = 0;
-}
- | function_post KW_CONST
-{
- $$ = $1 | (int)CPPFunctionType::F_const_method;
-}
- | function_post KW_VOLATILE
-{
- $$ = $1 | (int)CPPFunctionType::F_volatile_method;
-}
- | function_post KW_NOEXCEPT
-{
- $$ = $1 | (int)CPPFunctionType::F_noexcept;
-}
- | function_post KW_NOEXCEPT_LPAREN const_expr ')'
-{
- CPPExpression::Result result = $3->evaluate();
- if (result._type == CPPExpression::RT_error) {
- yywarning("noexcept() requires a constant expression", @3);
- } else if (result.as_boolean()) {
- $$ = $1 | (int)CPPFunctionType::F_noexcept;
- }
-}
- | function_post KW_FINAL
-{
- $$ = $1 | (int)CPPFunctionType::F_final;
-}
- | function_post KW_OVERRIDE
-{
- $$ = $1 | (int)CPPFunctionType::F_override;
-}
- | function_post '&'
-{
- $$ = $1 | (int)CPPFunctionType::F_lvalue_method;
-}
- | function_post ANDAND
-{
- $$ = $1 | (int)CPPFunctionType::F_rvalue_method;
-}
- | function_post KW_MUTABLE
-{
- // Used for lambdas, currently ignored.
- $$ = $1;
-}
- | function_post KW_CONSTEXPR
-{
- // Used for lambdas in C++17, currently ignored.
- $$ = $1;
-}
- | function_post KW_THROW '(' ')'
-{
- $$ = $1;
-}
- | function_post KW_THROW '(' name ')'
-{
- $$ = $1;
-}
- | function_post KW_THROW '(' name ELLIPSIS ')'
-{
- $$ = $1;
-}
- ;
-
-function_operator:
- '!'
-{
- $$ = "!";
-}
- | '~'
-{
- $$ = "~";
-}
- | '*'
-{
- $$ = "*";
-}
- | '/'
-{
- $$ = "/";
-}
- | '%'
-{
- $$ = "%";
-}
- | '+'
-{
- $$ = "+";
-}
- | '-'
-{
- $$ = "-";
-}
- | '|'
-{
- $$ = "|";
-}
- | '&'
-{
- $$ = "&";
-}
- | '^'
-{
- $$ = "^";
-}
- | OROR
-{
- $$ = "||";
-}
- | ANDAND
-{
- $$ = "&&";
-}
- | EQCOMPARE
-{
- $$ = "==";
-}
- | NECOMPARE
-{
- $$ = "!=";
-}
- | LECOMPARE
-{
- $$ = "<=";
-}
- | GECOMPARE
-{
- $$ = ">=";
-}
- | '<'
-{
- $$ = "<";
-}
- | '>'
-{
- $$ = ">";
-}
- | SPACESHIP
-{
- $$ = "<=>";
-}
- | LSHIFT
-{
- $$ = "<<";
-}
- | RSHIFT
-{
- $$ = ">>";
-}
- | '='
-{
- $$ = "=";
-}
- | ','
-{
- $$ = ",";
-}
- | PLUSPLUS
-{
- $$ = "++";
-}
- | MINUSMINUS
-{
- $$ = "--";
-}
- | TIMESEQUAL
-{
- $$ = "*=";
-}
- | DIVIDEEQUAL
-{
- $$ = "/=";
-}
- | MODEQUAL
-{
- $$ = "%=";
-}
- | PLUSEQUAL
-{
- $$ = "+=";
-}
- | MINUSEQUAL
-{
- $$ = "-=";
-}
- | OREQUAL
-{
- $$ = "|=";
-}
- | ANDEQUAL
-{
- $$ = "&=";
-}
- | XOREQUAL
-{
- $$ = "^=";
-}
- | LSHIFTEQUAL
-{
- $$ = "<<=";
-}
- | RSHIFTEQUAL
-{
- $$ = ">>=";
-}
- | POINTSAT
-{
- $$ = "->";
-}
- | '[' ']'
-{
- $$ = "[]";
-}
- | '(' ')'
-{
- $$ = "()";
-}
- | KW_NEW
-{
- $$ = "new";
-}
- | KW_DELETE
-{
- $$ = "delete";
-}
- ;
-
-more_template_declaration:
- type_like_declaration
- | template_declaration
- | friend_declaration
- ;
-
-template_declaration:
- KW_EXTERN template_declaration
- | KW_TEMPLATE
-{
- push_scope(new CPPTemplateScope(current_scope));
-}
- '<' template_formal_parameters '>' more_template_declaration
-{
- pop_scope();
-}
- | KW_TEMPLATE type_like_declaration
- | KW_TEMPLATE friend_declaration
- ;
-
-template_formal_parameters:
- empty
- | template_nonempty_formal_parameters
- ;
-
-template_nonempty_formal_parameters:
- template_formal_parameter
-{
- CPPTemplateScope *ts = current_scope->as_template_scope();
- assert(ts != nullptr);
- ts->add_template_parameter($1);
-}
- | template_nonempty_formal_parameters ',' template_formal_parameter
-{
- CPPTemplateScope *ts = current_scope->as_template_scope();
- assert(ts != nullptr);
- ts->add_template_parameter($3);
-}
- ;
-
-typename_keyword:
- KW_CLASS
- | KW_TYPENAME
- ;
-
-template_formal_parameter:
- typename_keyword
-{
- $$ = CPPType::new_type(new CPPClassTemplateParameter(nullptr));
-}
- | typename_keyword name
-{
- $$ = CPPType::new_type(new CPPClassTemplateParameter($2));
-}
- | typename_keyword name '=' full_type
-{
- $$ = CPPType::new_type(new CPPClassTemplateParameter($2, $4));
-}
- | typename_keyword ELLIPSIS
-{
- CPPClassTemplateParameter *ctp = new CPPClassTemplateParameter(nullptr);
- ctp->_packed = true;
- $$ = CPPType::new_type(ctp);
-}
- | typename_keyword ELLIPSIS name
-{
- CPPClassTemplateParameter *ctp = new CPPClassTemplateParameter($3);
- ctp->_packed = true;
- $$ = CPPType::new_type(ctp);
-}
- | template_formal_parameter_type formal_parameter_identifier template_parameter_maybe_initialize
-{
- CPPInstance *inst = new CPPInstance($1, $2, 0, @2.file);
- inst->set_initializer($3);
- $$ = inst;
-}
- | KW_CONST template_formal_parameter_type formal_parameter_identifier template_parameter_maybe_initialize
-{
- $3->add_modifier(IIT_const);
- CPPInstance *inst = new CPPInstance($2, $3, 0, @3.file);
- inst->set_initializer($4);
- $$ = inst;
-}
- | template_formal_parameter_type parameter_pack_identifier
-{
- CPPInstance *inst = new CPPInstance($1, $2, 0, @2.file);
- $$ = inst;
-}
- | KW_CONST template_formal_parameter_type parameter_pack_identifier
-{
- $3->add_modifier(IIT_const);
- CPPInstance *inst = new CPPInstance($2, $3, 0, @3.file);
- $$ = inst;
-}
- | KW_VOLATILE template_formal_parameter_type formal_parameter_identifier template_parameter_maybe_initialize
-{
- $3->add_modifier(IIT_volatile);
- CPPInstance *inst = new CPPInstance($2, $3, 0, @3.file);
- inst->set_initializer($4);
- $$ = inst;
-}
- | KW_VOLATILE template_formal_parameter_type parameter_pack_identifier
-{
- $3->add_modifier(IIT_volatile);
- CPPInstance *inst = new CPPInstance($2, $3, 0, @3.file);
- $$ = inst;
-}
- ;
-
-template_formal_parameter_type:
- simple_type
-{
- $$ = CPPType::new_type($1);
-}
- | IDENTIFIER
-{
- yywarning("Not a type: " + $1->get_fully_scoped_name(), @1);
- $$ = CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_unknown));
-}
- | TYPENAME_IDENTIFIER
-{
- $$ = $1->find_type(current_scope, global_scope, false, current_lexer);
- if ($$ == nullptr) {
- yyerror(string("internal error resolving type ") + $1->get_fully_scoped_name(), @1);
- }
- assert($$ != nullptr);
-}
- | TYPEPACK_IDENTIFIER
-{
- $$ = $1->find_type(current_scope, global_scope, false, current_lexer);
- if ($$ == nullptr) {
- yyerror(string("internal error resolving type ") + $1->get_fully_scoped_name(), @1);
- }
- assert($$ != nullptr);
-}
- ;
-
-
-instance_identifier:
- name_no_final optional_attributes
-{
- $$ = new CPPInstanceIdentifier($1, $2);
-}
- | KW_OPERATOR function_operator optional_attributes
-{
- // For an operator function. We implement this simply by building a
- // ficticious name for the function; in other respects it's just
- // like a regular function.
- CPPIdentifier *ident = $1;
- if (ident == nullptr) {
- ident = new CPPIdentifier("operator "+$2, @2);
- } else {
- ident->_names.push_back("operator "+$2);
- }
-
- $$ = new CPPInstanceIdentifier(ident, $3);
-}
- | KW_OPERATOR SIMPLE_STRING IDENTIFIER optional_attributes
-{
- // A C++11 literal operator.
- if (!$2.empty()) {
- yyerror("expected empty string", @2);
- }
- CPPIdentifier *ident = $1;
- if (ident == nullptr) {
- ident = new CPPIdentifier("operator \"\" "+$3->get_simple_name(), @3);
- } else {
- ident->_names.push_back("operator \"\" "+$3->get_simple_name());
- }
-
- $$ = new CPPInstanceIdentifier(ident, $4);
-}
- | KW_CONST instance_identifier %prec UNARY
-{
- $$ = $2;
- $$->add_modifier(IIT_const);
-}
- | KW_VOLATILE instance_identifier %prec UNARY
-{
- $$ = $2;
- $$->add_modifier(IIT_volatile);
-}
- | '*' optional_attributes instance_identifier %prec UNARY
-{
- $$ = $3;
- $$->add_modifier(IIT_pointer, $2);
-}
- | '&' optional_attributes instance_identifier %prec UNARY
-{
- $$ = $3;
- $$->add_modifier(IIT_reference, $2);
-}
- | ANDAND optional_attributes instance_identifier %prec UNARY
-{
- $$ = $3;
- $$->add_modifier(IIT_rvalue_reference, $2);
-}
- | SCOPING '*' optional_attributes instance_identifier %prec UNARY
-{
- $$ = $4;
- $$->add_scoped_pointer_modifier($1, $3);
-}
- | instance_identifier '[' optional_const_expr ']' optional_attributes
-{
- $$ = $1;
- $$->add_array_modifier($3, $5);
-}
- | '(' instance_identifier ')'
-{
- $$ = $2;
- $$->add_modifier(IIT_paren);
-}
- | instance_identifier '('
-{
- // Create a scope for this function (in case it is a function)
- CPPScope *scope = new CPPScope($1->get_scope(current_scope, global_scope),
- CPPNameComponent(""), V_private);
-
- // It still needs to be able to pick up any template arguments, if this is
- // a definition for a method template. Add a fake "using" declaration to
- // accomplish this.
- scope->_using.insert(current_scope);
-
- push_scope(scope);
-}
- formal_parameter_list ')' function_post optional_attributes
-{
- pop_scope();
- $$ = $1;
- if ($4->is_parameter_expr() && $6 == 0) {
- // Oops, this must have been an instance declaration with a
- // parameter list, not a function prototype.
- $$->add_initializer_modifier($4);
- }
- else {
- // This was (probably) a function prototype.
- $$->add_func_modifier($4, $6, nullptr, $7);
- }
-}
- ;
-
-
-instance_identifier_and_maybe_trailing_return_type:
- instance_identifier maybe_trailing_return_type
-{
- // This is handled a bit awkwardly right now. Ideally it'd be wrapped
- // up in the instance_identifier rule, but then more needs to happen in
- // order to avoid shift/reduce conflicts.
- if ($2 != nullptr) {
- $1->add_trailing_return_type($2);
- }
- $$ = $1;
-}
- | instance_identifier ':' const_expr
-{
- // Bitfield definition.
- $1->_bit_width = $3;
- $$ = $1;
-}
- ;
-
-
-maybe_trailing_return_type:
- empty
-{
- $$ = nullptr;
-}
- | POINTSAT predefined_type empty_instance_identifier
-{
- $$ = $3->unroll_type($2);
-}
- | POINTSAT KW_CONST predefined_type empty_instance_identifier
-{
- $4->add_modifier(IIT_const);
- $$ = $4->unroll_type($3);
-}
- ;
-
-
-maybe_comma_identifier:
- empty
-{
- $$ = nullptr;
-}
- | ',' IDENTIFIER
-{
- $$ = $2;
-}
- ;
-
-
-function_parameter_list:
- empty
-{
- $$ = new CPPParameterList;
-}
- | ELLIPSIS
-{
- $$ = new CPPParameterList;
- $$->_includes_ellipsis = true;
-}
- | function_parameters
-{
- $$ = $1;
-}
- | function_parameters ',' ELLIPSIS
-{
- $$ = $1;
- $$->_includes_ellipsis = true;
-}
- | function_parameters ELLIPSIS
-{
- $$ = $1;
- $$->_includes_ellipsis = true;
-}
- ;
-
-function_parameters:
- function_parameter
-{
- $$ = new CPPParameterList;
- $$->_parameters.push_back($1);
-}
- | function_parameters ',' function_parameter
-{
- $$ = $1;
- $$->_parameters.push_back($3);
-}
- ;
-
-formal_parameter_list:
- empty
-{
- $$ = new CPPParameterList;
-}
- | ELLIPSIS
-{
- $$ = new CPPParameterList;
- $$->_includes_ellipsis = true;
-}
- | formal_parameters
-{
- $$ = $1;
-}
- | formal_parameters ',' ELLIPSIS
-{
- $$ = $1;
- $$->_includes_ellipsis = true;
-}
- | formal_parameters ELLIPSIS
-{
- $$ = $1;
- $$->_includes_ellipsis = true;
-}
- ;
-
-formal_parameters:
- formal_parameter
-{
- $$ = new CPPParameterList;
- $$->_parameters.push_back($1);
-}
- | formal_parameters ',' formal_parameter
-{
- $$ = $1;
- $$->_parameters.push_back($3);
-}
- ;
-
-template_parameter_maybe_initialize:
- empty
-{
- $$ = nullptr;
-}
- | '=' no_angle_bracket_const_expr
-{
- $$ = $2;
-}
- ;
-
-maybe_initialize:
- empty
-{
- $$ = nullptr;
-}
- | '=' const_expr
-{
- $$ = $2;
-}
- ;
-
-maybe_initialize_or_constructor_body:
- ';'
-{
- $$ = nullptr;
-}
- | '{' code '}'
-{
- $$ = nullptr;
-}
- | ':' constructor_inits '{' code '}'
-{
- $$ = nullptr;
-}
- | '=' KW_DEFAULT ';'
-{
- $$ = new CPPExpression(CPPExpression::get_default());
-}
- | '=' KW_DELETE ';'
-{
- $$ = new CPPExpression(CPPExpression::get_delete());
-}
- ;
-
-maybe_initialize_or_function_body:
- ';'
-{
- $$ = nullptr;
-}
- | '{' code '}'
-{
- $$ = nullptr;
-}
- | '=' const_expr ';'
-{
- $$ = $2;
-}
- | '=' KW_DEFAULT ';'
-{
- $$ = new CPPExpression(CPPExpression::get_default());
-}
- | '=' KW_DELETE ';'
-{
- $$ = new CPPExpression(CPPExpression::get_delete());
-}
- | '=' '{' structure_init '}'
-{
- $$ = nullptr;
-}
- ;
-
-structure_init:
- empty
- | structure_init_body
- | structure_init_body ','
- ;
-
-structure_init_body:
- const_expr
-{
-}
- | '{' structure_init '}'
- | structure_init_body ',' const_expr
- | structure_init_body ',' '{' structure_init '}'
- ;
-
-function_parameter:
- optional_attributes storage_class type formal_parameter_identifier maybe_initialize
-{
- if ($2 & CPPInstance::SC_const) {
- $4->add_modifier(IIT_const);
- }
- if ($2 & CPPInstance::SC_volatile) {
- $4->add_modifier(IIT_volatile);
- }
- $4->add_attributes($1);
- $$ = new CPPInstance($3, $4, 0, @4.file);
- $$->set_initializer($5);
-}
- | optional_attributes storage_class type_pack parameter_pack_identifier maybe_initialize
-{
- if ($2 & CPPInstance::SC_const) {
- $4->add_modifier(IIT_const);
- }
- if ($2 & CPPInstance::SC_volatile) {
- $4->add_modifier(IIT_volatile);
- }
- $4->add_attributes($1);
- $$ = new CPPInstance($3, $4, 0, @4.file);
- $$->set_initializer($5);
-}
- ;
-
-/* A "formal parameter" is like a function parameter, except that it parses
- * instance declarations (that look like functions declaration) as well, and
- * as such accepts constexpr parameters.
- */
-formal_parameter:
- function_parameter
-{
- $$ = $1;
-}
- | formal_const_expr
-{
- CPPType *type =
- CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_parameter));
- $$ = new CPPInstance(type, "expr");
- $$->set_initializer($1);
-}
- ;
-
-not_paren_formal_parameter_identifier:
- empty
-{
- $$ = new CPPInstanceIdentifier(nullptr);
-}
- | name_no_final optional_attributes
-{
- $$ = new CPPInstanceIdentifier($1, $2);
-}
- | KW_CONST not_paren_formal_parameter_identifier %prec UNARY
-{
- $$ = $2;
- $$->add_modifier(IIT_const);
-}
- | KW_VOLATILE not_paren_formal_parameter_identifier %prec UNARY
-{
- $$ = $2;
- $$->add_modifier(IIT_volatile);
-}
- | KW_RESTRICT not_paren_formal_parameter_identifier %prec UNARY
-{
- $$ = $2;
- $$->add_modifier(IIT_restrict);
-}
- | '*' optional_attributes not_paren_formal_parameter_identifier %prec UNARY
-{
- $$ = $3;
- $$->add_modifier(IIT_pointer, $2);
-}
- | '&' optional_attributes not_paren_formal_parameter_identifier %prec UNARY
-{
- $$ = $3;
- $$->add_modifier(IIT_reference, $2);
-}
- | ANDAND optional_attributes not_paren_formal_parameter_identifier %prec UNARY
-{
- $$ = $3;
- $$->add_modifier(IIT_rvalue_reference, $2);
-}
- | SCOPING '*' optional_attributes not_paren_formal_parameter_identifier %prec UNARY
-{
- $$ = $4;
- $$->add_scoped_pointer_modifier($1, $3);
-}
- | not_paren_formal_parameter_identifier '[' optional_const_expr ']' optional_attributes
-{
- $$ = $1;
- $$->add_array_modifier($3, $5);
-}
- ;
-
-formal_parameter_identifier:
- empty
-{
- $$ = new CPPInstanceIdentifier(nullptr);
-}
- | name_no_final optional_attributes
-{
- $$ = new CPPInstanceIdentifier($1, $2);
-}
- | KW_CONST formal_parameter_identifier %prec UNARY
-{
- $$ = $2;
- $$->add_modifier(IIT_const);
-}
- | KW_VOLATILE formal_parameter_identifier %prec UNARY
-{
- $$ = $2;
- $$->add_modifier(IIT_volatile);
-}
- | KW_RESTRICT formal_parameter_identifier %prec UNARY
-{
- $$ = $2;
- $$->add_modifier(IIT_restrict);
-}
- | '*' optional_attributes formal_parameter_identifier %prec UNARY
-{
- $$ = $3;
- $$->add_modifier(IIT_pointer, $2);
-}
- | '&' optional_attributes formal_parameter_identifier %prec UNARY
-{
- $$ = $3;
- $$->add_modifier(IIT_reference, $2);
-}
- | ANDAND optional_attributes formal_parameter_identifier %prec UNARY
-{
- $$ = $3;
- $$->add_modifier(IIT_rvalue_reference, $2);
-}
- | SCOPING '*' optional_attributes formal_parameter_identifier %prec UNARY
-{
- $$ = $4;
- $$->add_scoped_pointer_modifier($1, $3);
-}
- | formal_parameter_identifier '[' optional_const_expr ']' optional_attributes
-{
- $$ = $1;
- $$->add_array_modifier($3, $5);
-}
- | '(' formal_parameter_identifier ')' '(' function_parameter_list ')' function_post optional_attributes
-{
- $$ = $2;
- $$->add_modifier(IIT_paren);
- $$->add_func_modifier($5, $7, nullptr, $8);
-}
- | '(' formal_parameter_identifier ')'
-{
- $$ = $2;
- $$->add_modifier(IIT_paren);
-}
- ;
-
-parameter_pack_identifier:
- ELLIPSIS
-{
- $$ = new CPPInstanceIdentifier(nullptr);
- $$->_packed = true;
-}
- | ELLIPSIS name optional_attributes
-{
- $$ = new CPPInstanceIdentifier($2, $3);
- $$->_packed = true;
-}
- | KW_CONST parameter_pack_identifier %prec UNARY
-{
- $$ = $2;
- $$->add_modifier(IIT_const);
-}
- | KW_VOLATILE parameter_pack_identifier %prec UNARY
-{
- $$ = $2;
- $$->add_modifier(IIT_volatile);
-}
- | KW_RESTRICT parameter_pack_identifier %prec UNARY
-{
- $$ = $2;
- $$->add_modifier(IIT_restrict);
-}
- | '*' optional_attributes parameter_pack_identifier %prec UNARY
-{
- $$ = $3;
- $$->add_modifier(IIT_pointer, $2);
-}
- | '&' optional_attributes parameter_pack_identifier %prec UNARY
-{
- $$ = $3;
- $$->add_modifier(IIT_reference, $2);
-}
- | ANDAND optional_attributes parameter_pack_identifier %prec UNARY
-{
- $$ = $3;
- $$->add_modifier(IIT_rvalue_reference, $2);
-}
- | SCOPING '*' optional_attributes parameter_pack_identifier %prec UNARY
-{
- $$ = $4;
- $$->add_scoped_pointer_modifier($1, $3);
-}
- | parameter_pack_identifier '[' optional_const_expr ']' optional_attributes
-{
- $$ = $1;
- $$->add_array_modifier($3, $5);
-}
- | '(' parameter_pack_identifier ')' '(' function_parameter_list ')' function_post optional_attributes
-{
- $$ = $2;
- $$->add_modifier(IIT_paren);
- $$->add_func_modifier($5, $7, nullptr, $8);
-}
- | '(' parameter_pack_identifier ')'
-{
- $$ = $2;
- $$->add_modifier(IIT_paren);
-}
- ;
-
-not_paren_empty_instance_identifier:
- empty
-{
- $$ = new CPPInstanceIdentifier(nullptr);
-}
- | ELLIPSIS
-{
- $$ = new CPPInstanceIdentifier(nullptr);
- $$->_packed = true;
-}
- | ELLIPSIS name optional_attributes
-{
- $$ = new CPPInstanceIdentifier($2, $3);
- $$->_packed = true;
-}
- | KW_CONST not_paren_empty_instance_identifier %prec UNARY
-{
- $$ = $2;
- $$->add_modifier(IIT_const);
-}
- | KW_VOLATILE not_paren_empty_instance_identifier %prec UNARY
-{
- $$ = $2;
- $$->add_modifier(IIT_volatile);
-}
- | KW_RESTRICT not_paren_empty_instance_identifier %prec UNARY
-{
- $$ = $2;
- $$->add_modifier(IIT_restrict);
-}
- | '*' optional_attributes not_paren_empty_instance_identifier %prec UNARY
-{
- $$ = $3;
- $$->add_modifier(IIT_pointer, $2);
-}
- | '&' optional_attributes not_paren_empty_instance_identifier %prec UNARY
-{
- $$ = $3;
- $$->add_modifier(IIT_reference, $2);
-}
- | ANDAND optional_attributes not_paren_empty_instance_identifier %prec UNARY
-{
- $$ = $3;
- $$->add_modifier(IIT_rvalue_reference, $2);
-}
- | SCOPING '*' optional_attributes not_paren_empty_instance_identifier %prec UNARY
-{
- $$ = $4;
- $$->add_scoped_pointer_modifier($1, $3);
-}
- | not_paren_empty_instance_identifier '[' optional_const_expr ']' optional_attributes
-{
- $$ = $1;
- $$->add_array_modifier($3, $5);
-}
- ;
-
-empty_instance_identifier:
- empty
-{
- $$ = new CPPInstanceIdentifier(nullptr);
-}
- | ELLIPSIS
-{
- $$ = new CPPInstanceIdentifier(nullptr);
- $$->_packed = true;
-}
- | ELLIPSIS name optional_attributes
-{
- $$ = new CPPInstanceIdentifier($2, $3);
- $$->_packed = true;
-}
- | KW_CONST empty_instance_identifier %prec UNARY
-{
- $$ = $2;
- $$->add_modifier(IIT_const);
-}
- | KW_VOLATILE empty_instance_identifier %prec UNARY
-{
- $$ = $2;
- $$->add_modifier(IIT_volatile);
-}
- | KW_RESTRICT empty_instance_identifier %prec UNARY
-{
- $$ = $2;
- $$->add_modifier(IIT_restrict);
-}
- | '*' optional_attributes not_paren_empty_instance_identifier %prec UNARY
-{
- $$ = $3;
- $$->add_modifier(IIT_pointer, $2);
-}
- | '&' optional_attributes not_paren_empty_instance_identifier %prec UNARY
-{
- $$ = $3;
- $$->add_modifier(IIT_reference, $2);
-}
- | ANDAND optional_attributes not_paren_empty_instance_identifier %prec UNARY
-{
- $$ = $3;
- $$->add_modifier(IIT_rvalue_reference, $2);
-}
- | SCOPING '*' optional_attributes not_paren_empty_instance_identifier %prec UNARY
-{
- $$ = $4;
- $$->add_scoped_pointer_modifier($1, $3);
-}
- | not_paren_empty_instance_identifier '[' optional_const_expr ']' optional_attributes
-{
- $$ = $1;
- $$->add_array_modifier($3, $5);
-}
- | '(' function_parameter_list ')' function_post optional_attributes maybe_trailing_return_type
-{
- $$ = new CPPInstanceIdentifier(nullptr);
- $$->add_modifier(IIT_paren);
- $$->add_func_modifier($2, $4, $6, $5);
-}
- | '(' '*' optional_attributes not_paren_empty_instance_identifier ')' '(' function_parameter_list ')' function_post optional_attributes maybe_trailing_return_type
-{
- $$ = $4;
- $$->add_modifier(IIT_pointer, $3);
- $$->add_modifier(IIT_paren);
- $$->add_func_modifier($7, $9, $11, $10);
-}
- | '(' '&' optional_attributes not_paren_empty_instance_identifier ')' '(' function_parameter_list ')' function_post optional_attributes maybe_trailing_return_type
-{
- $$ = $4;
- $$->add_modifier(IIT_reference, $3);
- $$->add_modifier(IIT_paren);
- $$->add_func_modifier($7, $9, $11, $10);
-}
- | '(' ANDAND optional_attributes not_paren_empty_instance_identifier ')' '(' function_parameter_list ')' function_post optional_attributes maybe_trailing_return_type
-{
- $$ = $4;
- $$->add_modifier(IIT_rvalue_reference, $3);
- $$->add_modifier(IIT_paren);
- $$->add_func_modifier($7, $9, $11, $10);
-}
- ;
-
-type:
- simple_type
-{
- $$ = CPPType::new_type($1);
-}
- | TYPENAME_IDENTIFIER
-{
- $$ = $1->find_type(current_scope, global_scope, false, current_lexer);
- if ($$ == nullptr) {
- yyerror(string("internal error resolving type ") + $1->get_fully_scoped_name(), @1);
- }
- assert($$ != nullptr);
-}
- | KW_TYPENAME name
-{
- $$ = CPPType::new_type(new CPPTBDType($2));
-}
- | anonymous_struct
-{
- $$ = CPPType::new_type($1);
-}
- | named_struct
-{
- $$ = CPPType::new_type($1);
-}
- | enum
-{
- $$ = CPPType::new_type($1);
-}
- | struct_keyword optional_attributes name
-{
- CPPType *type = $3->find_type(current_scope, global_scope, false, current_lexer);
- if (type != nullptr) {
- $$ = type;
- } else {
- CPPExtensionType *et =
- CPPType::new_type(new CPPExtensionType($1, $3, current_scope, @1.file, $2))
- ->as_extension_type();
- CPPScope *scope = $3->get_scope(current_scope, global_scope);
- if (scope != nullptr) {
- scope->define_extension_type(et);
- }
- $$ = et;
- }
-}
- | enum_keyword optional_attributes name_no_final ':' enum_element_type
-{
- CPPType *type = $3->find_type(current_scope, global_scope, false, current_lexer);
- if (type != nullptr) {
- $$ = type;
- } else {
- CPPExtensionType *et =
- CPPType::new_type(new CPPExtensionType($1, $3, current_scope, @1.file, $2))
- ->as_extension_type();
- CPPScope *scope = $3->get_scope(current_scope, global_scope);
- if (scope != nullptr) {
- scope->define_extension_type(et);
- }
- $$ = et;
- }
-}
- | KW_DECLTYPE '(' const_expr ')'
-{
- $$ = $3->determine_type();
- if ($$ == nullptr) {
- stringstream str;
- str << *$3;
- yyerror("could not determine type of " + str.str(), @3);
- }
-}
- | KW_DECLTYPE '(' KW_AUTO ')'
-{
- $$ = CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_auto));
-}
- | KW_UNDERLYING_TYPE '(' full_type ')'
-{
- CPPEnumType *enum_type = $3->as_enum_type();
- if (enum_type == nullptr) {
- yyerror("an enumeration type is required", @3);
- $$ = $3;
- } else {
- $$ = enum_type->get_underlying_type();
- }
-}
- | KW_AUTO
-{
- $$ = CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_auto));
-}
- | KW_BUILTIN_VA_LIST
-{
- $$ = CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_va_list));
-}
- ;
-
-type_pack:
- TYPEPACK_IDENTIFIER
-{
- $$ = $1->find_type(current_scope, global_scope, false, current_lexer);
- if ($$ == nullptr) {
- yyerror(string("internal error resolving type ") + $1->get_fully_scoped_name(), @1);
- }
- assert($$ != nullptr);
-}
- ;
-
-type_decl:
- simple_type
-{
- $$ = CPPType::new_type($1);
-}
- | TYPENAME_IDENTIFIER
-{
- $$ = $1->find_type(current_scope, global_scope, false, current_lexer);
- if ($$ == nullptr) {
- yyerror(string("internal error resolving type ") + $1->get_fully_scoped_name(), @1);
- }
- assert($$ != nullptr);
-}
- | KW_TYPENAME name
-{
- $$ = CPPType::new_type(new CPPTBDType($2));
-}
- | anonymous_struct
-{
- $$ = CPPType::new_type($1);
-}
- | named_struct
-{
- $$ = new CPPTypeDeclaration(CPPType::new_type($1));
-}
- | enum
-{
- $$ = new CPPTypeDeclaration(CPPType::new_type($1));
-}
- | struct_keyword optional_attributes name
-{
- CPPType *type = $3->find_type(current_scope, global_scope, false, current_lexer);
- if (type != nullptr) {
- $$ = type;
- } else {
- CPPExtensionType *et =
- CPPType::new_type(new CPPExtensionType($1, $3, current_scope, @1.file, $2))
- ->as_extension_type();
- CPPScope *scope = $3->get_scope(current_scope, global_scope);
- if (scope != nullptr) {
- scope->define_extension_type(et);
- }
- $$ = et;
- }
-}
- | enum_keyword optional_attributes name_no_final ':' enum_element_type
-{
- CPPType *type = $3->find_type(current_scope, global_scope, false, current_lexer);
- if (type != nullptr) {
- $$ = type;
- } else {
- CPPExtensionType *et =
- CPPType::new_type(new CPPExtensionType($1, $3, current_scope, @1.file, $2))
- ->as_extension_type();
- CPPScope *scope = $3->get_scope(current_scope, global_scope);
- if (scope != nullptr) {
- scope->define_extension_type(et);
- }
- $$ = et;
- }
-}
- | enum_keyword optional_attributes name
-{
- yywarning(string("C++ does not permit forward declaration of untyped enum ") + $3->get_fully_scoped_name(), @1);
-
- CPPType *type = $3->find_type(current_scope, global_scope, false, current_lexer);
- if (type != nullptr) {
- $$ = type;
- } else {
- CPPExtensionType *et =
- CPPType::new_type(new CPPExtensionType($1, $3, current_scope, @1.file, $2))
- ->as_extension_type();
- CPPScope *scope = $3->get_scope(current_scope, global_scope);
- if (scope != nullptr) {
- scope->define_extension_type(et);
- }
- $$ = et;
- }
-}
- | KW_DECLTYPE '(' const_expr ')'
-{
- $$ = $3->determine_type();
- if ($$ == nullptr) {
- stringstream str;
- str << *$3;
- yyerror("could not determine type of " + str.str(), @3);
- }
-}
- | KW_DECLTYPE '(' KW_AUTO ')'
-{
- $$ = CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_auto));
-}
- | KW_UNDERLYING_TYPE '(' full_type ')'
-{
- CPPEnumType *enum_type = $3->as_enum_type();
- if (enum_type == nullptr) {
- yyerror("an enumeration type is required", @3);
- $$ = $3;
- } else {
- $$ = enum_type->get_underlying_type();
- }
-}
- | KW_AUTO
-{
- $$ = CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_auto));
-}
- | KW_BUILTIN_VA_LIST
-{
- $$ = CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_va_list));
-}
- ;
-
-predefined_type:
- simple_type
-{
- $$ = CPPType::new_type($1);
-}
- | TYPENAME_IDENTIFIER
-{
- $$ = $1->find_type(current_scope, global_scope, false, current_lexer);
- if ($$ == nullptr) {
- yyerror(string("internal error resolving type ") + $1->get_fully_scoped_name(), @1);
- }
- assert($$ != nullptr);
-}
- | KW_TYPENAME name
-{
- $$ = CPPType::new_type(new CPPTBDType($2));
-}
- | struct_keyword optional_attributes name
-{
- CPPType *type = $3->find_type(current_scope, global_scope, false, current_lexer);
- if (type != nullptr) {
- $$ = type;
- } else {
- CPPExtensionType *et =
- CPPType::new_type(new CPPExtensionType($1, $3, current_scope, @1.file, $2))
- ->as_extension_type();
- CPPScope *scope = $3->get_scope(current_scope, global_scope);
- if (scope != nullptr) {
- scope->define_extension_type(et);
- }
- $$ = et;
- }
-}
- | enum_keyword optional_attributes name
-{
- CPPType *type = $3->find_type(current_scope, global_scope, false, current_lexer);
- if (type != nullptr) {
- $$ = type;
- } else {
- CPPExtensionType *et =
- CPPType::new_type(new CPPExtensionType($1, $3, current_scope, @1.file, $2))
- ->as_extension_type();
- CPPScope *scope = $3->get_scope(current_scope, global_scope);
- if (scope != nullptr) {
- scope->define_extension_type(et);
- }
- $$ = et;
- }
-}
- | KW_DECLTYPE '(' const_expr ')'
-{
- $$ = $3->determine_type();
- if ($$ == nullptr) {
- stringstream str;
- str << *$3;
- yyerror("could not determine type of " + str.str(), @3);
- }
-}
- | KW_UNDERLYING_TYPE '(' full_type ')'
-{
- CPPEnumType *enum_type = $3->as_enum_type();
- if (enum_type == nullptr) {
- yyerror("an enumeration type is required", @3);
- $$ = $3;
- } else {
- $$ = enum_type->get_underlying_type();
- }
-}
- | KW_AUTO
-{
- $$ = CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_auto));
-}
- | KW_BUILTIN_VA_LIST
-{
- $$ = CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_va_list));
-}
- ;
-
-var_type_decl:
- type_decl
-{
- $$ = $1;
-}
- | IDENTIFIER
-{
- yyerror(string("unknown type '") + $1->get_fully_scoped_name() + "'", @1);
-
- $$ = CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_unknown));
-}
-
-full_type:
- type empty_instance_identifier
-{
- $$ = $2->unroll_type($1);
-}
- | KW_CONST type empty_instance_identifier
-{
- $3->add_modifier(IIT_const);
- $$ = $3->unroll_type($2);
-}
- | type_pack empty_instance_identifier
-{
- $$ = $2->unroll_type($1);
-}
- | KW_CONST type_pack empty_instance_identifier
-{
- $3->add_modifier(IIT_const);
- $$ = $3->unroll_type($2);
-}
- ;
-
-anonymous_struct:
- struct_keyword optional_attributes '{'
-{
- CPPVisibility starting_vis =
- ($1 == CPPExtensionType::T_class) ? V_private : V_public;
-
- CPPScope *new_scope = new CPPScope(current_scope, CPPNameComponent("anon"),
- starting_vis);
- CPPStructType *st = new CPPStructType($1, nullptr, current_scope,
- new_scope, @1.file, $2);
- new_scope->set_struct_type(st);
-
- push_scope(new_scope);
- push_struct(st);
-}
- cpp '}'
-{
- $$ = current_struct;
- current_struct->_incomplete = false;
- pop_struct();
- pop_scope();
-}
- ;
-
-named_struct:
- struct_keyword optional_attributes name_no_final
-{
- CPPVisibility starting_vis =
- ($1 == CPPExtensionType::T_class) ? V_private : V_public;
-
- CPPScope *scope = $3->get_scope(current_scope, global_scope, current_lexer);
- if (scope == nullptr) {
- scope = current_scope;
- }
- CPPScope *new_scope = new CPPScope(scope, $3->_names.back(),
- starting_vis);
-
- CPPStructType *st = new CPPStructType($1, $3, current_scope,
- new_scope, @1.file, $2);
- new_scope->set_struct_type(st);
- current_scope->define_extension_type(st);
-
- push_scope(new_scope);
- push_struct(st);
-}
- maybe_final maybe_class_derivation '{' cpp '}'
-{
- $$ = current_struct;
- current_struct->_incomplete = false;
- pop_struct();
- pop_scope();
-}
- ;
-
-maybe_final:
- empty
- | KW_FINAL
-{
- current_struct->_final = true;
-}
- ;
-
-maybe_class_derivation:
- empty
- | class_derivation
- ;
-
-class_derivation:
- ':' base_specification
- | class_derivation ',' base_specification
- ;
-
-base_specification:
- class_derivation_name
-{
- current_struct->append_derivation($1, V_unknown, false);
-}
- | KW_PUBLIC class_derivation_name
-{
- current_struct->append_derivation($2, V_public, false);
-}
- | KW_PROTECTED class_derivation_name
-{
- current_struct->append_derivation($2, V_protected, false);
-}
- | KW_PRIVATE class_derivation_name
-{
- current_struct->append_derivation($2, V_private, false);
-}
- | KW_VIRTUAL KW_PUBLIC class_derivation_name
-{
- current_struct->append_derivation($3, V_public, true);
-}
- | KW_VIRTUAL KW_PROTECTED class_derivation_name
-{
- current_struct->append_derivation($3, V_protected, true);
-}
- | KW_VIRTUAL KW_PRIVATE class_derivation_name
-{
- current_struct->append_derivation($3, V_private, true);
-}
- | KW_PUBLIC KW_VIRTUAL class_derivation_name
-{
- current_struct->append_derivation($3, V_public, true);
-}
- | KW_PROTECTED KW_VIRTUAL class_derivation_name
-{
- current_struct->append_derivation($3, V_protected, true);
-}
- | KW_PRIVATE KW_VIRTUAL class_derivation_name
-{
- current_struct->append_derivation($3, V_private, true);
-}
- ;
-
-enum:
- enum_decl
-{
- if (current_enum->_scope != nullptr) {
- push_scope(current_enum->_scope);
- }
-}
- '{' enum_body '}'
-{
- if (current_enum->_scope != nullptr) {
- pop_scope();
- }
- $$ = current_enum;
- current_enum = nullptr;
-}
- ;
-
-enum_decl:
- enum_keyword optional_attributes ':' enum_element_type
-{
- current_enum = new CPPEnumType($1, nullptr, $4, current_scope, nullptr, @1.file, $2);
-}
- | enum_keyword optional_attributes
-{
- current_enum = new CPPEnumType($1, nullptr, current_scope, nullptr, @1.file, $2);
-}
- | enum_keyword optional_attributes name_no_final ':' enum_element_type
-{
- CPPScope *new_scope = new CPPScope(current_scope, $3->_names.back(), V_public);
- current_enum = new CPPEnumType($1, $3, $5, current_scope, new_scope, @1.file, $2);
-}
- | enum_keyword optional_attributes name_no_final
-{
- CPPScope *new_scope = new CPPScope(current_scope, $3->_names.back(), V_public);
- current_enum = new CPPEnumType($1, $3, current_scope, new_scope, @1.file, $2);
-}
- ;
-
-enum_element_type:
- simple_int_type
-{
- $$ = CPPType::new_type($1);
-}
- | TYPENAME_IDENTIFIER
-{
- $$ = $1->find_type(current_scope, global_scope, false, current_lexer);
-}
- ;
-
-enum_body_trailing_comma:
- empty
- | enum_body_trailing_comma name optional_attributes ','
-{
- assert(current_enum != nullptr);
- current_enum->add_element($2->get_simple_name(), nullptr, current_lexer, @2, $3);
-}
- | enum_body_trailing_comma name optional_attributes '=' const_expr ','
-{
- assert(current_enum != nullptr);
- current_enum->add_element($2->get_simple_name(), $5, current_lexer, @2, $3);
-};
-
-enum_body:
- enum_body_trailing_comma
- | enum_body_trailing_comma name optional_attributes
-{
- assert(current_enum != nullptr);
- current_enum->add_element($2->get_simple_name(), nullptr, current_lexer, @2, $3);
-}
- | enum_body_trailing_comma name optional_attributes '=' const_expr
-{
- assert(current_enum != nullptr);
- current_enum->add_element($2->get_simple_name(), $5, current_lexer, @2, $3);
-}
- ;
-
-enum_keyword:
- KW_ENUM
-{
- $$ = CPPExtensionType::T_enum;
-}
- | KW_ENUM KW_CLASS
-{
- $$ = CPPExtensionType::T_enum_class;
-}
- | KW_ENUM KW_STRUCT
-{
- $$ = CPPExtensionType::T_enum_struct;
-}
- ;
-
-struct_keyword:
- KW_CLASS
-{
- $$ = CPPExtensionType::T_class;
-}
- | KW_STRUCT
-{
- $$ = CPPExtensionType::T_struct;
-}
- | KW_UNION
-{
- $$ = CPPExtensionType::T_union;
-}
- ;
-
-namespace_declaration:
- KW_NAMESPACE optional_attributes name '{'
-{
- CPPScope *scope = $3->find_scope(current_scope, global_scope, current_lexer);
- if (scope == nullptr) {
- // This must be a new namespace declaration.
- CPPScope *parent_scope =
- $3->get_scope(current_scope, global_scope, current_lexer);
- if (parent_scope == nullptr) {
- parent_scope = current_scope;
- }
- scope = new CPPScope(parent_scope, $3->_names.back(), V_public);
- }
-
- CPPNamespace *nspace = new CPPNamespace($3, scope, @1.file, $2);
- current_scope->add_declaration(nspace, global_scope, current_lexer, @1);
- current_scope->define_namespace(nspace);
- push_scope(scope);
-}
- cpp '}'
-{
- pop_scope();
-}
- | KW_INLINE KW_NAMESPACE name '{'
-{
- CPPScope *scope = $3->find_scope(current_scope, global_scope, current_lexer);
- if (scope == nullptr) {
- // This must be a new namespace declaration.
- CPPScope *parent_scope =
- $3->get_scope(current_scope, global_scope, current_lexer);
- if (parent_scope == nullptr) {
- parent_scope = current_scope;
- }
- scope = new CPPScope(parent_scope, $3->_names.back(), V_public);
- }
-
- CPPNamespace *nspace = new CPPNamespace($3, scope, @2.file);
- nspace->_is_inline = true;
- current_scope->add_declaration(nspace, global_scope, current_lexer, @2);
- current_scope->define_namespace(nspace);
- push_scope(scope);
-}
- cpp '}'
-{
- pop_scope();
-}
- | KW_NAMESPACE '{' cpp '}'
- | KW_INLINE KW_NAMESPACE '{' cpp '}'
- ;
-
-using_declaration:
- KW_USING name ';'
-{
- CPPUsing *using_decl = new CPPUsing($2, false, @1.file);
- current_scope->add_declaration(using_decl, global_scope, current_lexer, @1);
- current_scope->add_using(using_decl, global_scope, current_lexer);
-}
- | KW_USING name optional_attributes '=' full_type ';'
-{
- // This is really just an alternative way to declare a typedef.
- CPPTypedefType *typedef_type = new CPPTypedefType($5, $2, current_scope, $3);
- typedef_type->_using = true;
- current_scope->add_declaration(CPPType::new_type(typedef_type), global_scope, current_lexer, @1);
-}
- | KW_USING KW_NAMESPACE name ';'
-{
- CPPUsing *using_decl = new CPPUsing($3, true, @1.file);
- current_scope->add_declaration(using_decl, global_scope, current_lexer, @1);
- current_scope->add_using(using_decl, global_scope, current_lexer);
-}
- | KW_USING KW_ENUM name ';'
-{
- CPPUsing *using_decl = new CPPUsing($3, false, @1.file);
- current_scope->add_declaration(using_decl, global_scope, current_lexer, @1);
- current_scope->add_using(using_decl, global_scope, current_lexer);
-}
- ;
-
-simple_type:
- simple_int_type
- | simple_float_type
- | simple_void_type
- ;
-
-simple_int_type:
- KW_BOOL
-{
- $$ = new CPPSimpleType(CPPSimpleType::T_bool);
-}
- | KW_CHAR
-{
- $$ = new CPPSimpleType(CPPSimpleType::T_char);
-}
- | KW_WCHAR_T
-{
- $$ = new CPPSimpleType(CPPSimpleType::T_wchar_t);
-}
- | KW_CHAR8_T
-{
- $$ = new CPPSimpleType(CPPSimpleType::T_char8_t);
-}
- | KW_CHAR16_T
-{
- $$ = new CPPSimpleType(CPPSimpleType::T_char16_t);
-}
- | KW_CHAR32_T
-{
- $$ = new CPPSimpleType(CPPSimpleType::T_char32_t);
-}
- | KW_SHORT
-{
- $$ = new CPPSimpleType(CPPSimpleType::T_int,
- CPPSimpleType::F_short);
-}
- | KW_LONG
-{
- $$ = new CPPSimpleType(CPPSimpleType::T_int,
- CPPSimpleType::F_long);
-}
- | KW_UNSIGNED
-{
- $$ = new CPPSimpleType(CPPSimpleType::T_int,
- CPPSimpleType::F_unsigned);
-}
- | KW_SIGNED
-{
- $$ = new CPPSimpleType(CPPSimpleType::T_int,
- CPPSimpleType::F_signed);
-}
- | KW_INT
-{
- $$ = new CPPSimpleType(CPPSimpleType::T_int);
-}
- | KW_SHORT simple_int_type
-{
- $$ = $2;
- $$->_flags |= CPPSimpleType::F_short;
-}
- | KW_LONG simple_int_type
-{
- $$ = $2;
- if ($$->_flags & CPPSimpleType::F_long) {
- $$->_flags |= CPPSimpleType::F_longlong;
- } else {
- $$->_flags |= CPPSimpleType::F_long;
- }
-}
- | KW_UNSIGNED simple_int_type
-{
- $$ = $2;
- $$->_flags |= CPPSimpleType::F_unsigned;
-}
- | KW_SIGNED simple_int_type
-{
- $$ = $2;
- $$->_flags |= CPPSimpleType::F_signed;
-}
- ;
-
-simple_float_type:
- KW_FLOAT
-{
- $$ = new CPPSimpleType(CPPSimpleType::T_float);
-}
- | KW_DOUBLE
-{
- $$ = new CPPSimpleType(CPPSimpleType::T_double);
-}
- | KW_LONG KW_DOUBLE
-{
- $$ = new CPPSimpleType(CPPSimpleType::T_double,
- CPPSimpleType::F_long);
-}
- ;
-
-simple_void_type:
- KW_VOID
-{
- $$ = new CPPSimpleType(CPPSimpleType::T_void);
-}
- ;
-
-/* We don't care what the code is. We just want to be sure we match
- up opening and closing braces properly. For anything else, we'll
- accept just token salad. */
-code:
-{
- current_lexer->_resolve_identifiers = false;
-}
- code_block
-{
- current_lexer->_resolve_identifiers = true;
-}
- ;
-
-code_block:
- empty
- | code_block element
- ;
-
-element:
- REAL
- | INTEGER
- | SIMPLE_STRING
- | STRING_LITERAL
- | CUSTOM_LITERAL
- | CHAR_TOK
- | IDENTIFIER
- | TYPENAME_IDENTIFIER
- | TYPEPACK_IDENTIFIER
- | SCOPING
- | SIMPLE_IDENTIFIER
- | ELLIPSIS | OROR | ANDAND
- | EQCOMPARE | NECOMPARE | LECOMPARE | GECOMPARE | SPACESHIP
- | LSHIFT | RSHIFT | POINTSAT_STAR | DOT_STAR | POINTSAT
- | SCOPE | PLUSPLUS | MINUSMINUS
- | TIMESEQUAL | DIVIDEEQUAL | MODEQUAL | PLUSEQUAL | MINUSEQUAL
- | OREQUAL | ANDEQUAL | XOREQUAL | LSHIFTEQUAL | RSHIFTEQUAL
- | ATTR_LEFT | ATTR_RIGHT
- | KW_ALIGNAS | KW_ALIGNOF | KW_AUTO | KW_BOOL | KW_BUILTIN_VA_LIST
- | KW_CATCH | KW_CHAR | KW_CHAR8_T | KW_CHAR16_T | KW_CHAR32_T | KW_CLASS
- | KW_CONST | KW_CONSTEVAL | KW_CONSTEXPR | KW_CONSTINIT | KW_CONST_CAST
- | KW_DECLTYPE | KW_DEFAULT | KW_DELETE | KW_DOUBLE | KW_DYNAMIC_CAST
- | KW_ELSE | KW_ENUM | KW_EXTERN | KW_EXPLICIT | KW_EXPLICIT_LPAREN
- | KW_FALSE | KW_FINAL | KW_FLOAT | KW_FRIEND | KW_FOR
- | KW_GOTO | KW_IF | KW_INLINE | KW_INT | KW_LONG | KW_MUTABLE
- | KW_NAMESPACE | KW_NEW | KW_NOEXCEPT | KW_NOEXCEPT_LPAREN | KW_NULLPTR
- | KW_OPERATOR | KW_OVERRIDE | KW_PRIVATE | KW_PROTECTED
- | KW_PUBLIC | KW_PUBLISHED | KW_REGISTER | KW_REINTERPRET_CAST
- | KW_RESTRICT | KW_RETURN | KW_SHORT | KW_SIGNED | KW_SIZEOF | KW_STATIC
- | KW_STATIC_ASSERT | KW_STATIC_CAST | KW_STRUCT | KW_TEMPLATE
- | KW_THREAD_LOCAL | KW_THROW | KW_TRUE | KW_TRY | KW_TYPEDEF
- | KW_TYPEID | KW_TYPENAME | KW_UNDERLYING_TYPE | KW_UNION
- | KW_UNSIGNED | KW_USING | KW_VIRTUAL | KW_VOID | KW_VOLATILE
- | KW_WCHAR_T | KW_WHILE
-{
-}
- | '+' | '-' | '*' | '/' | '&' | '|' | '^' | '!' | '~' | '=' | '%'
- | '<' | '>' | '(' | ')' | '.' | ',' | ';' | ':' | '[' | ']'
- | '?' | '{' code_block '}'
- ;
-
-optional_const_expr:
- empty
-{
- $$ = nullptr;
-}
- | const_expr
-{
- $$ = $1;
-}
- ;
-
-optional_const_expr_comma:
- empty
-{
- $$ = nullptr;
-}
- | const_expr_comma
-{
- $$ = $1;
-}
- ;
-
-const_expr_comma:
- const_expr
-{
- $$ = $1;
-}
- | const_expr_comma ',' const_expr
-{
- $$ = new CPPExpression(',', $1, $3);
-}
- ;
-
-no_angle_bracket_const_expr:
- const_operand
-{
- $$ = $1;
-}
- | '(' full_type ')' no_angle_bracket_const_expr %prec UNARY
-{
- $$ = new CPPExpression(CPPExpression::typecast_op($2, $4));
-}
- | KW_STATIC_CAST '<' full_type '>' '(' const_expr_comma ')'
-{
- $$ = new CPPExpression(CPPExpression::typecast_op($3, $6, CPPExpression::T_static_cast));
-}
- | KW_DYNAMIC_CAST '<' full_type '>' '(' const_expr_comma ')'
-{
- $$ = new CPPExpression(CPPExpression::typecast_op($3, $6, CPPExpression::T_dynamic_cast));
-}
- | KW_CONST_CAST '<' full_type '>' '(' const_expr_comma ')'
-{
- $$ = new CPPExpression(CPPExpression::typecast_op($3, $6, CPPExpression::T_const_cast));
-}
- | KW_REINTERPRET_CAST '<' full_type '>' '(' const_expr_comma ')'
-{
- $$ = new CPPExpression(CPPExpression::typecast_op($3, $6, CPPExpression::T_reinterpret_cast));
-}
- | KW_SIZEOF '(' full_type ')' %prec UNARY
-{
- $$ = new CPPExpression(CPPExpression::sizeof_func($3));
-}
- | KW_SIZEOF no_angle_bracket_const_expr %prec UNARY
-{
- $$ = new CPPExpression(CPPExpression::sizeof_func($2));
-}
- | KW_SIZEOF ELLIPSIS '(' name ')' %prec UNARY
-{
- $$ = new CPPExpression(CPPExpression::sizeof_ellipsis_func($4));
-}
- | KW_ALIGNOF '(' full_type ')' %prec UNARY
-{
- $$ = new CPPExpression(CPPExpression::alignof_func($3));
-}
- | '!' no_angle_bracket_const_expr %prec UNARY
-{
- $$ = new CPPExpression(UNARY_NOT, $2);
-}
- | '~' no_angle_bracket_const_expr %prec UNARY
-{
- $$ = new CPPExpression(UNARY_NEGATE, $2);
-}
- | '-' no_angle_bracket_const_expr %prec UNARY
-{
- $$ = new CPPExpression(UNARY_MINUS, $2);
-}
- | '+' no_angle_bracket_const_expr %prec UNARY
-{
- $$ = new CPPExpression(UNARY_PLUS, $2);
-}
- | '*' no_angle_bracket_const_expr %prec UNARY
-{
- $$ = new CPPExpression(UNARY_STAR, $2);
-}
- | '&' no_angle_bracket_const_expr %prec UNARY
-{
- $$ = new CPPExpression(UNARY_REF, $2);
-}
- | no_angle_bracket_const_expr '*' no_angle_bracket_const_expr
-{
- $$ = new CPPExpression('*', $1, $3);
-}
- | no_angle_bracket_const_expr '/' no_angle_bracket_const_expr
-{
- $$ = new CPPExpression('/', $1, $3);
-}
- | no_angle_bracket_const_expr '%' no_angle_bracket_const_expr
-{
- $$ = new CPPExpression('%', $1, $3);
-}
- | no_angle_bracket_const_expr '+' no_angle_bracket_const_expr
-{
- $$ = new CPPExpression('+', $1, $3);
-}
- | no_angle_bracket_const_expr '-' no_angle_bracket_const_expr
-{
- $$ = new CPPExpression('-', $1, $3);
-}
- | no_angle_bracket_const_expr '|' no_angle_bracket_const_expr
-{
- $$ = new CPPExpression('|', $1, $3);
-}
- | no_angle_bracket_const_expr '^' no_angle_bracket_const_expr
-{
- $$ = new CPPExpression('^', $1, $3);
-}
- | no_angle_bracket_const_expr '&' no_angle_bracket_const_expr
-{
- $$ = new CPPExpression('&', $1, $3);
-}
- | no_angle_bracket_const_expr OROR no_angle_bracket_const_expr
-{
- $$ = new CPPExpression(OROR, $1, $3);
-}
- | no_angle_bracket_const_expr ANDAND no_angle_bracket_const_expr
-{
- $$ = new CPPExpression(ANDAND, $1, $3);
-}
- | no_angle_bracket_const_expr EQCOMPARE no_angle_bracket_const_expr
-{
- $$ = new CPPExpression(EQCOMPARE, $1, $3);
-}
- | no_angle_bracket_const_expr NECOMPARE no_angle_bracket_const_expr
-{
- $$ = new CPPExpression(NECOMPARE, $1, $3);
-}
- | no_angle_bracket_const_expr LECOMPARE no_angle_bracket_const_expr
-{
- $$ = new CPPExpression(LECOMPARE, $1, $3);
-}
- | no_angle_bracket_const_expr GECOMPARE no_angle_bracket_const_expr
-{
- $$ = new CPPExpression(GECOMPARE, $1, $3);
-}
- | no_angle_bracket_const_expr SPACESHIP no_angle_bracket_const_expr
-{
- $$ = new CPPExpression(SPACESHIP, $1, $3);
-}
- | no_angle_bracket_const_expr LSHIFT no_angle_bracket_const_expr
-{
- $$ = new CPPExpression(LSHIFT, $1, $3);
-}
- | no_angle_bracket_const_expr RSHIFT no_angle_bracket_const_expr
-{
- $$ = new CPPExpression(RSHIFT, $1, $3);
-}
- | no_angle_bracket_const_expr '?' no_angle_bracket_const_expr ':' no_angle_bracket_const_expr
-{
- $$ = new CPPExpression('?', $1, $3, $5);
-}
- | no_angle_bracket_const_expr '[' const_expr ']'
-{
- $$ = new CPPExpression('[', $1, $3);
-}
- | no_angle_bracket_const_expr '(' const_expr_comma ')'
-{
- $$ = new CPPExpression('f', $1, $3);
-}
- | no_angle_bracket_const_expr '(' ')'
-{
- $$ = new CPPExpression('f', $1);
-}
- | no_angle_bracket_const_expr '.' name
-{
- $$ = new CPPExpression('.', $1, new CPPExpression($3, current_scope, global_scope, current_lexer));
-}
- | no_angle_bracket_const_expr POINTSAT no_angle_bracket_const_expr
-{
- $$ = new CPPExpression(POINTSAT, $1, $3);
-}
- | '(' const_expr_comma ')'
-{
- $$ = $2;
-}
- ;
-
-
-const_expr:
- const_operand
-{
- $$ = $1;
-}
- | '(' full_type ')' const_expr %prec UNARY
-{
- $$ = new CPPExpression(CPPExpression::typecast_op($2, $4));
-}
- | KW_STATIC_CAST '<' full_type '>' '(' const_expr_comma ')'
-{
- $$ = new CPPExpression(CPPExpression::typecast_op($3, $6, CPPExpression::T_static_cast));
-}
- | KW_DYNAMIC_CAST '<' full_type '>' '(' const_expr_comma ')'
-{
- $$ = new CPPExpression(CPPExpression::typecast_op($3, $6, CPPExpression::T_dynamic_cast));
-}
- | KW_CONST_CAST '<' full_type '>' '(' const_expr_comma ')'
-{
- $$ = new CPPExpression(CPPExpression::typecast_op($3, $6, CPPExpression::T_const_cast));
-}
- | KW_REINTERPRET_CAST '<' full_type '>' '(' const_expr_comma ')'
-{
- $$ = new CPPExpression(CPPExpression::typecast_op($3, $6, CPPExpression::T_reinterpret_cast));
-}
- | TYPENAME_IDENTIFIER '(' optional_const_expr_comma ')'
-{
- // A constructor call.
- CPPType *type = $1->find_type(current_scope, global_scope, false, current_lexer);
- if (type == nullptr) {
- yyerror(string("internal error resolving type ") + $1->get_fully_scoped_name(), @1);
- }
- assert(type != nullptr);
- $$ = new CPPExpression(CPPExpression::construct_op(type, $3));
-}
- | TYPENAME_IDENTIFIER '{' optional_const_expr_comma '}'
-{
- // Aggregate initialization.
- CPPType *type = $1->find_type(current_scope, global_scope, false, current_lexer);
- if (type == nullptr) {
- yyerror(string("internal error resolving type ") + $1->get_fully_scoped_name(), @1);
- }
- assert(type != nullptr);
- $$ = new CPPExpression(CPPExpression::aggregate_init_op(type, $3));
-}
- | KW_INT '(' optional_const_expr_comma ')'
-{
- CPPType *type =
- CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_int));
- $$ = new CPPExpression(CPPExpression::construct_op(type, $3));
-}
- | KW_CHAR '(' optional_const_expr_comma ')'
-{
- CPPType *type =
- CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_char));
- $$ = new CPPExpression(CPPExpression::construct_op(type, $3));
-}
- | KW_WCHAR_T '(' optional_const_expr_comma ')'
-{
- CPPType *type =
- CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_wchar_t));
- $$ = new CPPExpression(CPPExpression::construct_op(type, $3));
-}
- | KW_CHAR8_T '(' optional_const_expr_comma ')'
-{
- CPPType *type =
- CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_char8_t));
- $$ = new CPPExpression(CPPExpression::construct_op(type, $3));
-}
- | KW_CHAR16_T '(' optional_const_expr_comma ')'
-{
- CPPType *type =
- CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_char16_t));
- $$ = new CPPExpression(CPPExpression::construct_op(type, $3));
-}
- | KW_CHAR32_T '(' optional_const_expr_comma ')'
-{
- CPPType *type =
- CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_char32_t));
- $$ = new CPPExpression(CPPExpression::construct_op(type, $3));
-}
- | KW_BOOL '(' optional_const_expr_comma ')'
-{
- CPPType *type =
- CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_bool));
- $$ = new CPPExpression(CPPExpression::construct_op(type, $3));
-}
- | KW_SHORT '(' optional_const_expr_comma ')'
-{
- CPPType *type =
- CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_int,
- CPPSimpleType::F_short));
- $$ = new CPPExpression(CPPExpression::construct_op(type, $3));
-}
- | KW_LONG '(' optional_const_expr_comma ')'
-{
- CPPType *type =
- CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_int,
- CPPSimpleType::F_long));
- $$ = new CPPExpression(CPPExpression::construct_op(type, $3));
-}
- | KW_UNSIGNED '(' optional_const_expr_comma ')'
-{
- CPPType *type =
- CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_int,
- CPPSimpleType::F_unsigned));
- $$ = new CPPExpression(CPPExpression::construct_op(type, $3));
-}
- | KW_SIGNED '(' optional_const_expr_comma ')'
-{
- CPPType *type =
- CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_int,
- CPPSimpleType::F_signed));
- $$ = new CPPExpression(CPPExpression::construct_op(type, $3));
-}
- | KW_FLOAT '(' optional_const_expr_comma ')'
-{
- CPPType *type =
- CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_float));
- $$ = new CPPExpression(CPPExpression::construct_op(type, $3));
-}
- | KW_DOUBLE '(' optional_const_expr_comma ')'
-{
- CPPType *type =
- CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_double));
- $$ = new CPPExpression(CPPExpression::construct_op(type, $3));
-}
- | KW_SIZEOF '(' full_type ')' %prec UNARY
-{
- $$ = new CPPExpression(CPPExpression::sizeof_func($3));
-}
- | KW_SIZEOF const_expr %prec UNARY
-{
- $$ = new CPPExpression(CPPExpression::sizeof_func($2));
-}
- | KW_SIZEOF ELLIPSIS '(' name ')' %prec UNARY
-{
- $$ = new CPPExpression(CPPExpression::sizeof_ellipsis_func($4));
-}
- | KW_ALIGNOF '(' full_type ')' %prec UNARY
-{
- $$ = new CPPExpression(CPPExpression::alignof_func($3));
-}
- | KW_NEW predefined_type %prec UNARY
-{
- $$ = new CPPExpression(CPPExpression::new_op($2));
-}
- | KW_NEW predefined_type '(' optional_const_expr_comma ')' %prec UNARY
-{
- $$ = new CPPExpression(CPPExpression::new_op($2, $4));
-}
- | KW_TYPEID '(' full_type ')'
-{
- CPPIdentifier ident("");
- ident.add_name("std");
- ident.add_name("type_info");
- CPPType *std_type_info = ident.find_type(current_scope, global_scope, false, current_lexer);
- if (!std_type_info) {
- yywarning("cannot use typeid before including ", @1);
- }
- $$ = new CPPExpression(CPPExpression::typeid_op($3, std_type_info));
-}
- | KW_TYPEID '(' const_expr ')'
-{
- CPPIdentifier ident("");
- ident.add_name("std");
- ident.add_name("type_info");
- CPPType *std_type_info = ident.find_type(current_scope, global_scope, false, current_lexer);
- if (!std_type_info) {
- yywarning("cannot use typeid before including ", @1);
- }
- $$ = new CPPExpression(CPPExpression::typeid_op($3, std_type_info));
-}
- | '!' const_expr %prec UNARY
-{
- $$ = new CPPExpression(UNARY_NOT, $2);
-}
- | '~' const_expr %prec UNARY
-{
- $$ = new CPPExpression(UNARY_NEGATE, $2);
-}
- | '-' const_expr %prec UNARY
-{
- $$ = new CPPExpression(UNARY_MINUS, $2);
-}
- | '+' const_expr %prec UNARY
-{
- $$ = new CPPExpression(UNARY_PLUS, $2);
-}
- | '*' const_expr %prec UNARY
-{
- $$ = new CPPExpression(UNARY_STAR, $2);
-}
- | '&' const_expr %prec UNARY
-{
- $$ = new CPPExpression(UNARY_REF, $2);
-}
- | const_expr '*' const_expr
-{
- $$ = new CPPExpression('*', $1, $3);
-}
- | const_expr '/' const_expr
-{
- $$ = new CPPExpression('/', $1, $3);
-}
- | const_expr '%' const_expr
-{
- $$ = new CPPExpression('%', $1, $3);
-}
- | const_expr '+' const_expr
-{
- $$ = new CPPExpression('+', $1, $3);
-}
- | const_expr '-' const_expr
-{
- $$ = new CPPExpression('-', $1, $3);
-}
- | const_expr '|' const_expr
-{
- $$ = new CPPExpression('|', $1, $3);
-}
- | const_expr '^' const_expr
-{
- $$ = new CPPExpression('^', $1, $3);
-}
- | const_expr '&' const_expr
-{
- $$ = new CPPExpression('&', $1, $3);
-}
- | const_expr OROR const_expr
-{
- $$ = new CPPExpression(OROR, $1, $3);
-}
- | const_expr ANDAND const_expr
-{
- $$ = new CPPExpression(ANDAND, $1, $3);
-}
- | const_expr EQCOMPARE const_expr
-{
- $$ = new CPPExpression(EQCOMPARE, $1, $3);
-}
- | const_expr NECOMPARE const_expr
-{
- $$ = new CPPExpression(NECOMPARE, $1, $3);
-}
- | const_expr LECOMPARE const_expr
-{
- $$ = new CPPExpression(LECOMPARE, $1, $3);
-}
- | const_expr GECOMPARE const_expr
-{
- $$ = new CPPExpression(GECOMPARE, $1, $3);
-}
- | const_expr SPACESHIP const_expr
-{
- $$ = new CPPExpression(SPACESHIP, $1, $3);
-}
- | const_expr '<' const_expr
-{
- $$ = new CPPExpression('<', $1, $3);
-}
- | const_expr '>' const_expr
-{
- $$ = new CPPExpression('>', $1, $3);
-}
- | const_expr LSHIFT const_expr
-{
- $$ = new CPPExpression(LSHIFT, $1, $3);
-}
- | const_expr RSHIFT const_expr
-{
- $$ = new CPPExpression(RSHIFT, $1, $3);
-}
- | const_expr '?' const_expr ':' const_expr
-{
- $$ = new CPPExpression('?', $1, $3, $5);
-}
- | const_expr '[' const_expr ']'
-{
- $$ = new CPPExpression('[', $1, $3);
-}
- | const_expr '(' const_expr_comma ')'
-{
- $$ = new CPPExpression('f', $1, $3);
-}
- | const_expr '(' ')'
-{
- $$ = new CPPExpression('f', $1);
-}
- | KW_NOEXCEPT_LPAREN const_expr ')'
-{
- $$ = new CPPExpression(KW_NOEXCEPT, $2);
-}
- | const_expr '.' name
-{
- $$ = new CPPExpression('.', $1, new CPPExpression($3, current_scope, global_scope, current_lexer));
-}
- | const_expr POINTSAT const_expr
-{
- $$ = new CPPExpression(POINTSAT, $1, $3);
-}
- | '(' const_expr_comma ')'
-{
- $$ = $2;
-}
- ;
-
-const_operand:
- INTEGER
-{
- $$ = new CPPExpression($1);
-}
- | KW_TRUE
-{
- $$ = new CPPExpression(true);
-}
- | KW_FALSE
-{
- $$ = new CPPExpression(false);
-}
- | CHAR_TOK
-{
- $$ = new CPPExpression($1);
-}
- | REAL
-{
- $$ = new CPPExpression($1);
-}
- | string_literal
-{
- $$ = $1;
-}
- | CUSTOM_LITERAL
-{
- $$ = $1;
-}
- | IDENTIFIER
-{
- $$ = new CPPExpression($1, current_scope, global_scope, current_lexer);
-}
- | KW_FINAL
-{
- // A variable named "final". C++11 explicitly permits this.
- CPPIdentifier *ident = new CPPIdentifier("final", @1);
- $$ = new CPPExpression(ident, current_scope, global_scope, current_lexer);
-}
- | KW_OVERRIDE
-{
- // A variable named "override". C++11 explicitly permits this.
- CPPIdentifier *ident = new CPPIdentifier("override", @1);
- $$ = new CPPExpression(ident, current_scope, global_scope, current_lexer);
-}
- | KW_NULLPTR
-{
- $$ = new CPPExpression(CPPExpression::get_nullptr());
-}
- | '[' capture_list ']' function_post optional_attributes maybe_trailing_return_type '{' code '}'
-{
- $2->_flags = $4;
- $2->_attributes = $5;
- $2->_return_type = $6;
- $$ = new CPPExpression(CPPExpression::lambda($2));
-}
- | '[' capture_list ']' '(' function_parameter_list ')' function_post optional_attributes maybe_trailing_return_type '{' code '}'
-{
- $2->_parameters = $5;
- $2->_flags = $7;
- $2->_attributes = $8;
- $2->_return_type = $9;
- $$ = new CPPExpression(CPPExpression::lambda($2));
-}
- | KW_HAS_VIRTUAL_DESTRUCTOR '(' full_type ')'
-{
- $$ = new CPPExpression(CPPExpression::type_trait(KW_HAS_VIRTUAL_DESTRUCTOR, $3));
-}
- | KW_IS_ABSTRACT '(' full_type ')'
-{
- $$ = new CPPExpression(CPPExpression::type_trait(KW_IS_ABSTRACT, $3));
-}
- | KW_IS_BASE_OF '(' full_type ',' full_type ')'
-{
- $$ = new CPPExpression(CPPExpression::type_trait(KW_IS_CLASS, $3, $5));
-}
- | KW_IS_CLASS '(' full_type ')'
-{
- $$ = new CPPExpression(CPPExpression::type_trait(KW_IS_CLASS, $3));
-}
- | KW_IS_CONSTRUCTIBLE '(' full_type ')'
-{
- $$ = new CPPExpression(CPPExpression::type_trait(KW_IS_CONSTRUCTIBLE, $3));
-}
- | KW_IS_CONSTRUCTIBLE '(' full_type ',' full_type ')'
-{
- $$ = new CPPExpression(CPPExpression::type_trait(KW_IS_CONSTRUCTIBLE, $3, $5));
-}
- | KW_IS_CONVERTIBLE_TO '(' full_type ',' full_type ')'
-{
- $$ = new CPPExpression(CPPExpression::type_trait(KW_IS_CONVERTIBLE_TO, $3, $5));
-}
- | KW_IS_DESTRUCTIBLE '(' full_type ')'
-{
- $$ = new CPPExpression(CPPExpression::type_trait(KW_IS_DESTRUCTIBLE, $3));
-}
- | KW_IS_EMPTY '(' full_type ')'
-{
- $$ = new CPPExpression(CPPExpression::type_trait(KW_IS_EMPTY, $3));
-}
- | KW_IS_ENUM '(' full_type ')'
-{
- $$ = new CPPExpression(CPPExpression::type_trait(KW_IS_ENUM, $3));
-}
- | KW_IS_FINAL '(' full_type ')'
-{
- $$ = new CPPExpression(CPPExpression::type_trait(KW_IS_FINAL, $3));
-}
- | KW_IS_FUNDAMENTAL '(' full_type ')'
-{
- $$ = new CPPExpression(CPPExpression::type_trait(KW_IS_FUNDAMENTAL, $3));
-}
- | KW_IS_POD '(' full_type ')'
-{
- $$ = new CPPExpression(CPPExpression::type_trait(KW_IS_POD, $3));
-}
- | KW_IS_POLYMORPHIC '(' full_type ')'
-{
- $$ = new CPPExpression(CPPExpression::type_trait(KW_IS_POLYMORPHIC, $3));
-}
- | KW_IS_STANDARD_LAYOUT '(' full_type ')'
-{
- $$ = new CPPExpression(CPPExpression::type_trait(KW_IS_STANDARD_LAYOUT, $3));
-}
- | KW_IS_TRIVIAL '(' full_type ')'
-{
- $$ = new CPPExpression(CPPExpression::type_trait(KW_IS_TRIVIAL, $3));
-}
- | KW_IS_TRIVIALLY_COPYABLE '(' full_type ')'
-{
- $$ = new CPPExpression(CPPExpression::type_trait(KW_IS_TRIVIALLY_COPYABLE, $3));
-}
- | KW_IS_UNION '(' full_type ')'
-{
- $$ = new CPPExpression(CPPExpression::type_trait(KW_IS_UNION, $3));
-}
- ;
-
-/* This is used for a const_expr as a "formal parameter", which really
- means an instance declaration using a parameter list (which looks a
- lot like a function prototype). It differs from const_expr mainly
- in that it forbids some expressions unless they are parenthesized,
- to avoid shift/reduce conflicts with the actual formal parameter
- definition. */
-
-formal_const_expr:
- formal_const_operand
-{
- $$ = $1;
-}
- | '(' full_type ')' const_expr %prec UNARY
-{
- $$ = new CPPExpression(CPPExpression::typecast_op($2, $4));
-}
- | KW_STATIC_CAST '<' full_type '>' '(' const_expr_comma ')'
-{
- $$ = new CPPExpression(CPPExpression::typecast_op($3, $6, CPPExpression::T_static_cast));
-}
- | KW_DYNAMIC_CAST '<' full_type '>' '(' const_expr_comma ')'
-{
- $$ = new CPPExpression(CPPExpression::typecast_op($3, $6, CPPExpression::T_dynamic_cast));
-}
- | KW_CONST_CAST '<' full_type '>' '(' const_expr_comma ')'
-{
- $$ = new CPPExpression(CPPExpression::typecast_op($3, $6, CPPExpression::T_const_cast));
-}
- | KW_REINTERPRET_CAST '<' full_type '>' '(' const_expr_comma ')'
-{
- $$ = new CPPExpression(CPPExpression::typecast_op($3, $6, CPPExpression::T_reinterpret_cast));
-}
- | KW_SIZEOF '(' full_type ')' %prec UNARY
-{
- $$ = new CPPExpression(CPPExpression::sizeof_func($3));
-}
- | KW_SIZEOF formal_const_expr %prec UNARY
-{
- $$ = new CPPExpression(CPPExpression::sizeof_func($2));
-}
- | KW_SIZEOF ELLIPSIS '(' name ')' %prec UNARY
-{
- $$ = new CPPExpression(CPPExpression::sizeof_ellipsis_func($4));
-}
- | KW_ALIGNOF '(' full_type ')' %prec UNARY
-{
- $$ = new CPPExpression(CPPExpression::alignof_func($3));
-}
- | KW_NEW predefined_type %prec UNARY
-{
- $$ = new CPPExpression(CPPExpression::new_op($2));
-}
- | KW_NEW predefined_type '(' optional_const_expr_comma ')' %prec UNARY
-{
- $$ = new CPPExpression(CPPExpression::new_op($2, $4));
-}
- | KW_TYPEID '(' full_type ')'
-{
- CPPIdentifier ident("");
- ident.add_name("std");
- ident.add_name("type_info");
- CPPType *std_type_info = ident.find_type(current_scope, global_scope, false, current_lexer);
- if (!std_type_info) {
- yywarning("cannot use typeid before including ", @1);
- }
- $$ = new CPPExpression(CPPExpression::typeid_op($3, std_type_info));
-}
- | KW_TYPEID '(' const_expr ')'
-{
- CPPIdentifier ident("");
- ident.add_name("std");
- ident.add_name("type_info");
- CPPType *std_type_info = ident.find_type(current_scope, global_scope, false, current_lexer);
- if (!std_type_info) {
- yywarning("cannot use typeid before including ", @1);
- }
- $$ = new CPPExpression(CPPExpression::typeid_op($3, std_type_info));
-}
- | '!' const_expr %prec UNARY
-{
- $$ = new CPPExpression(UNARY_NOT, $2);
-}
- | '~' const_expr %prec UNARY
-{
- $$ = new CPPExpression(UNARY_NEGATE, $2);
-}
- | '-' const_expr %prec UNARY
-{
- $$ = new CPPExpression(UNARY_MINUS, $2);
-}
- | '+' const_expr %prec UNARY
-{
- $$ = new CPPExpression(UNARY_PLUS, $2);
-}
- | '&' const_expr %prec UNARY
-{
- $$ = new CPPExpression(UNARY_REF, $2);
-}
- | formal_const_expr '*' const_expr
-{
- $$ = new CPPExpression('*', $1, $3);
-}
- | formal_const_expr '/' const_expr
-{
- $$ = new CPPExpression('/', $1, $3);
-}
- | formal_const_expr '%' const_expr
-{
- $$ = new CPPExpression('%', $1, $3);
-}
- | formal_const_expr '+' const_expr
-{
- $$ = new CPPExpression('+', $1, $3);
-}
- | formal_const_expr '-' const_expr
-{
- $$ = new CPPExpression('-', $1, $3);
-}
- | formal_const_expr '|' const_expr
-{
- $$ = new CPPExpression('|', $1, $3);
-}
- | formal_const_expr '^' const_expr
-{
- $$ = new CPPExpression('^', $1, $3);
-}
- | formal_const_expr '&' const_expr
-{
- $$ = new CPPExpression('&', $1, $3);
-}
- | formal_const_expr OROR const_expr
-{
- $$ = new CPPExpression(OROR, $1, $3);
-}
- | formal_const_expr ANDAND const_expr
-{
- $$ = new CPPExpression(ANDAND, $1, $3);
-}
- | formal_const_expr EQCOMPARE const_expr
-{
- $$ = new CPPExpression(EQCOMPARE, $1, $3);
-}
- | formal_const_expr NECOMPARE const_expr
-{
- $$ = new CPPExpression(NECOMPARE, $1, $3);
-}
- | formal_const_expr LECOMPARE const_expr
-{
- $$ = new CPPExpression(LECOMPARE, $1, $3);
-}
- | formal_const_expr GECOMPARE const_expr
-{
- $$ = new CPPExpression(GECOMPARE, $1, $3);
-}
- | formal_const_expr SPACESHIP const_expr
-{
- $$ = new CPPExpression(SPACESHIP, $1, $3);
-}
- | formal_const_expr '<' const_expr
-{
- $$ = new CPPExpression('<', $1, $3);
-}
- | formal_const_expr '>' const_expr
-{
- $$ = new CPPExpression('>', $1, $3);
-}
- | formal_const_expr LSHIFT const_expr
-{
- $$ = new CPPExpression(LSHIFT, $1, $3);
-}
- | formal_const_expr RSHIFT const_expr
-{
- $$ = new CPPExpression(RSHIFT, $1, $3);
-}
- | formal_const_expr '?' const_expr ':' const_expr
-{
- $$ = new CPPExpression('?', $1, $3, $5);
-}
- | formal_const_expr '[' const_expr ']'
-{
- $$ = new CPPExpression('[', $1, $3);
-}
- | formal_const_expr '(' const_expr_comma ')'
-{
- $$ = new CPPExpression('f', $1, $3);
-}
- | formal_const_expr '(' ')'
-{
- $$ = new CPPExpression('f', $1);
-}
- | formal_const_expr '.' name
-{
- $$ = new CPPExpression('.', $1, new CPPExpression($3, current_scope, global_scope, current_lexer));
-}
- | formal_const_expr POINTSAT const_expr
-{
- $$ = new CPPExpression(POINTSAT, $1, $3);
-}
- | '(' const_expr_comma ')'
-{
- $$ = $2;
-}
- ;
-
-formal_const_operand:
- INTEGER
-{
- $$ = new CPPExpression($1);
-}
- | KW_TRUE
-{
- $$ = new CPPExpression(true);
-}
- | KW_FALSE
-{
- $$ = new CPPExpression(false);
-}
- | CHAR_TOK
-{
- $$ = new CPPExpression($1);
-}
- | REAL
-{
- $$ = new CPPExpression($1);
-}
- | string_literal
-{
- $$ = $1;
-}
- | CUSTOM_LITERAL
-{
- $$ = $1;
-}
- | IDENTIFIER
-{
- $$ = new CPPExpression($1, current_scope, global_scope, current_lexer);
-}
- | KW_FINAL
-{
- // A variable named "final". C++11 explicitly permits this.
- CPPIdentifier *ident = new CPPIdentifier("final", @1);
- $$ = new CPPExpression(ident, current_scope, global_scope, current_lexer);
-}
- | KW_OVERRIDE
-{
- // A variable named "override". C++11 explicitly permits this.
- CPPIdentifier *ident = new CPPIdentifier("override", @1);
- $$ = new CPPExpression(ident, current_scope, global_scope, current_lexer);
-}
- | KW_NULLPTR
-{
- $$ = new CPPExpression(CPPExpression::get_nullptr());
-}
- ;
-
-/* The contents of the [] list preceding a lambda expression. */
-capture_list:
- empty
-{
- $$ = new CPPClosureType();
-}
- | '='
-{
- $$ = new CPPClosureType(CPPClosureType::CT_by_value);
-}
- | '&'
-{
- $$ = new CPPClosureType(CPPClosureType::CT_by_reference);
-}
- | capture maybe_initialize
-{
- $$ = new CPPClosureType();
- $1->_initializer = $2;
- $$->_captures.push_back(*$1);
- delete $1;
-}
- | capture_list ',' capture maybe_initialize
-{
- $$ = $1;
- $3->_initializer = $4;
- $$->_captures.push_back(*$3);
- delete $3;
-}
- ;
-
-capture:
- '&' name
-{
- $$ = new CPPClosureType::Capture;
- $$->_name = $2->get_simple_name();
- $$->_type = CPPClosureType::CT_by_reference;
-}
- | '&' name ELLIPSIS
-{
- $$ = new CPPClosureType::Capture;
- $$->_name = $2->get_simple_name();
- $$->_type = CPPClosureType::CT_by_reference;
-}
- | name
-{
- $$ = new CPPClosureType::Capture;
- $$->_name = $1->get_simple_name();
- if ($$->_name == "this") {
- $$->_type = CPPClosureType::CT_by_reference;
- } else {
- $$->_type = CPPClosureType::CT_by_value;
- }
-}
- | '*' name
-{
- $$ = new CPPClosureType::Capture;
- $$->_name = $2->get_simple_name();
- $$->_type = CPPClosureType::CT_by_value;
- if ($$->_name != "this") {
- yywarning("only capture name 'this' may be preceded by an asterisk", @2);
- }
-}
- ;
-
-class_derivation_name:
- name
-{
- CPPType *type = $1->find_type(current_scope, global_scope, true);
- if (type == nullptr) {
- type = CPPType::new_type(new CPPTBDType($1));
- }
- $$ = type;
-}
- | KW_TYPENAME name
-{
- $$ = CPPType::new_type(new CPPTBDType($2));
-}
- | name ELLIPSIS
-{
- CPPClassTemplateParameter *ctp = new CPPClassTemplateParameter($1);
- ctp->_packed = true;
- $$ = CPPType::new_type(ctp);
-}
- ;
-
-/*
-typedefname:
- TYPENAME_IDENTIFIER
-{
- CPPType *type = $1->find_type(current_scope, global_scope, false, current_lexer);
- if (type == NULL) {
- yyerror(string("internal error resolving type ") + $1->get_fully_scoped_name(), @1);
- }
- assert(type != NULL);
- $$ = type;
-}
- | KW_TYPENAME name
-{
- $$ = CPPType::new_type(new CPPTBDType($2));
-}
- ;
-*/
-
-
-/* Note that we should also accept "final" and "override" as valid names,
- * according to C++11. */
-name:
- IDENTIFIER
-{
- $$ = $1;
-}
- | TYPENAME_IDENTIFIER
-{
- $$ = $1;
-}
- | TYPEPACK_IDENTIFIER
-{
- $$ = $1;
-}
- | KW_FINAL
-{
- $$ = new CPPIdentifier("final", @1);
-}
- | KW_OVERRIDE
-{
- $$ = new CPPIdentifier("override", @1);
-}
- | KW_SIGNED
-{
- // This is not a keyword in Python, so it is useful to be able to use this
- // in MAKE_PROPERTY definitions, etc.
- $$ = new CPPIdentifier("signed", @1);
-}
- | KW_FLOAT
-{
- $$ = new CPPIdentifier("float", @1);
-}
- | KW_PUBLIC
-{
- $$ = new CPPIdentifier("public", @1);
-}
- | KW_PRIVATE
-{
- $$ = new CPPIdentifier("private", @1);
-}
- | KW_STATIC
-{
- $$ = new CPPIdentifier("static", @1);
-}
- | KW_DEFAULT
-{
- $$ = new CPPIdentifier("default", @1);
-}
- ;
-
-
-/* A variant on name that's used for structs, where we disallow final
- * to disambiguate the case of struct A final {};
- */
-name_no_final:
- IDENTIFIER
-{
- $$ = $1;
-}
- | TYPENAME_IDENTIFIER
-{
- $$ = $1;
-}
- | TYPEPACK_IDENTIFIER
-{
- $$ = $1;
-}
- | KW_OVERRIDE
-{
- $$ = new CPPIdentifier("override", @1);
-}
- ;
-
-
-string_literal:
- SIMPLE_STRING
-{
- $$ = new CPPExpression($1);
-}
- | STRING_LITERAL
-{
- $$ = $1;
-}
- | string_literal SIMPLE_STRING
-{
- // The right string takes on the literal type of the left.
- $$ = $1;
- $$->_str += $2;
-}
- | string_literal STRING_LITERAL
-{
- // We have to check that the two literal types match up.
- $$ = $1;
- if ($2->_type != CPPExpression::T_string && $2->_type != $1->_type) {
- yywarning("cannot concatenate two string literals of different types", @$);
- }
- $$->_str += $2->_str;
-}
- ;
-
-empty:
- ;
diff --git a/dtool/src/cppparser/cppBisonDefs.h b/dtool/src/cppparser/cppBisonDefs.h
deleted file mode 100644
index 2859ee30ab..0000000000
--- a/dtool/src/cppparser/cppBisonDefs.h
+++ /dev/null
@@ -1,124 +0,0 @@
-/**
- * PANDA 3D SOFTWARE
- * Copyright (c) Carnegie Mellon University. All rights reserved.
- *
- * All use of this software is subject to the terms of the revised BSD
- * license. You should have received a copy of this license along
- * with this source code in a file named "LICENSE."
- *
- * @file cppBisonDefs.h
- * @author drose
- * @date 1999-01-17
- */
-
-#ifndef CPPBISON_H
-#define CPPBISON_H
-
-// This header file defines the interface to the yacc (actually, bison) parser
-// and grammar. None of these interfaces are intended to be used directly;
-// they're defined here strictly to be used by the CPPParser and
-// CPPExpressionParser classes.
-
-#include "dtoolbase.h"
-
-#include
-
-#include "cppAttributeList.h"
-#include "cppClosureType.h"
-#include "cppExtensionType.h"
-#include "cppFile.h"
-
-class CPPParser;
-class CPPExpression;
-class CPPPreprocessor;
-class CPPDeclaration;
-class CPPInstance;
-class CPPType;
-class CPPStructType;
-class CPPEnumType;
-class CPPSimpleType;
-class CPPInstanceIdentifier;
-class CPPParameterList;
-class CPPTemplateParameterList;
-class CPPScope;
-class CPPIdentifier;
-class CPPCaptureType;
-
-void parse_cpp(CPPParser *cp);
-CPPExpression *parse_const_expr(CPPPreprocessor *pp,
- CPPScope *new_current_scope,
- CPPScope *new_global_scope);
-CPPType *parse_type(CPPPreprocessor *pp,
- CPPScope *new_current_scope,
- CPPScope *new_global_scope);
-
-extern CPPScope *current_scope;
-extern CPPScope *global_scope;
-extern CPPPreprocessor *current_lexer;
-
-
-// This structure holds the return value for each token. Traditionally, this
-// is a union, and is declared with the %union declaration in the parser.y
-// file, but unions are pretty worthless in C++ (you can't include an object
-// that has member functions in a union), so we'll use a class instead. That
-// means we need to declare it externally, here.
-
-class cppyystype {
-public:
- std::string str;
- CPPAttributeList attr_list;
- union {
- unsigned long long integer;
- long double real;
- CPPScope *scope;
- CPPDeclaration *decl;
- CPPInstance *instance;
- CPPType *type;
- CPPStructType *struct_type;
- CPPEnumType *enum_type;
- CPPSimpleType *simple_type;
- CPPInstanceIdentifier *inst_ident;
- CPPParameterList *param_list;
- CPPTemplateParameterList *template_param_list;
- CPPExtensionType::Type extension_enum;
- CPPExpression *expr;
- CPPIdentifier *identifier;
- CPPClosureType *closure_type;
- CPPClosureType::Capture *capture;
- } u;
-};
-#define YYSTYPE cppyystype
-
-// This structure takes advantage of a bison feature to track the exact
-// location in the file of each token, for more useful error reporting. We
-// define it up here so we can reference it in the lexer.
-
-struct cppyyltype {
- // Bison expects these members to be part of this struct.
- int first_line;
- int first_column;
- int last_line;
- int last_column;
-
- // Early versions of bison (1.25 and earlier) expected these members to be
- // in this struct as well.
- int timestamp;
- char *text;
-
- // The remaining members are added for this application and have no meaning
- // to bison.
- CPPFile file;
-};
-#define YYLTYPE cppyyltype
-
-// Beginning around bison 1.35 or so, we need to define this macro as well, to
-// tell bison how to collect multiple locations together. (The default
-// implementation copies only first_line through last_column, whereas here we
-// use the struct assignment operator to copy all the members of the
-// structure).
-#define YYLLOC_DEFAULT(Current, Rhs, N) \
- (Current) = (Rhs)[1]; \
- (Current).last_line = (Rhs)[N].last_line; \
- (Current).last_column = (Rhs)[N].last_column;
-
-#endif
diff --git a/dtool/src/cppparser/cppClassTemplateParameter.cxx b/dtool/src/cppparser/cppClassTemplateParameter.cxx
deleted file mode 100644
index 7c85eb6c24..0000000000
--- a/dtool/src/cppparser/cppClassTemplateParameter.cxx
+++ /dev/null
@@ -1,126 +0,0 @@
-/**
- * PANDA 3D SOFTWARE
- * Copyright (c) Carnegie Mellon University. All rights reserved.
- *
- * All use of this software is subject to the terms of the revised BSD
- * license. You should have received a copy of this license along
- * with this source code in a file named "LICENSE."
- *
- * @file cppClassTemplateParameter.cxx
- * @author drose
- * @date 1999-10-28
- */
-
-#include "cppClassTemplateParameter.h"
-#include "cppIdentifier.h"
-
-/**
- *
- */
-CPPClassTemplateParameter::
-CPPClassTemplateParameter(CPPIdentifier *ident, CPPType *default_type) :
- CPPType(CPPFile()),
- _ident(ident),
- _default_type(default_type),
- _packed(false)
-{
-}
-
-/**
- * Returns true if this declaration is an actual, factual declaration, or
- * false if some part of the declaration depends on a template parameter which
- * has not yet been instantiated.
- */
-bool CPPClassTemplateParameter::
-is_fully_specified() const {
- return false;
-}
-
-/**
- *
- */
-void CPPClassTemplateParameter::
-output(std::ostream &out, int indent_level, CPPScope *scope, bool complete) const {
- if (complete) {
- out << "class";
- if (_packed) {
- out << "...";
- }
- if (_ident != nullptr) {
- out << " ";
- _ident->output(out, scope);
- }
- if (_default_type) {
- out << " = ";
- _default_type->output(out, indent_level, scope, false);
- }
- } else {
- _ident->output(out, scope);
- }
-}
-
-
-/**
- *
- */
-CPPDeclaration::SubType CPPClassTemplateParameter::
-get_subtype() const {
- return ST_class_template_parameter;
-}
-
-/**
- *
- */
-CPPClassTemplateParameter *CPPClassTemplateParameter::
-as_class_template_parameter() {
- return this;
-}
-
-/**
- * Called by CPPDeclaration() to determine whether this type is equivalent to
- * another type of the same type.
- */
-bool CPPClassTemplateParameter::
-is_equal(const CPPDeclaration *other) const {
- const CPPClassTemplateParameter *ot = ((CPPDeclaration *)other)->as_class_template_parameter();
- assert(ot != nullptr);
-
- if (_default_type != ot->_default_type) {
- return false;
- }
-
- if (_packed != ot->_packed) {
- return false;
- }
-
- if (_ident == nullptr || ot->_ident == nullptr) {
- return _ident == ot->_ident;
- }
-
- return *_ident == *ot->_ident;
-}
-
-
-/**
- * Called by CPPDeclaration() to determine whether this type should be ordered
- * before another type of the same type, in an arbitrary but fixed ordering.
- */
-bool CPPClassTemplateParameter::
-is_less(const CPPDeclaration *other) const {
- const CPPClassTemplateParameter *ot = ((CPPDeclaration *)other)->as_class_template_parameter();
- assert(ot != nullptr);
-
- if (_default_type != ot->_default_type) {
- return _default_type < ot->_default_type;
- }
-
- if (_packed != ot->_packed) {
- return _packed < ot->_packed;
- }
-
- if (_ident == nullptr || ot->_ident == nullptr) {
- return _ident < ot->_ident;
- }
-
- return *_ident < *ot->_ident;
-}
diff --git a/dtool/src/cppparser/cppClassTemplateParameter.h b/dtool/src/cppparser/cppClassTemplateParameter.h
deleted file mode 100644
index 8ff6fe1538..0000000000
--- a/dtool/src/cppparser/cppClassTemplateParameter.h
+++ /dev/null
@@ -1,47 +0,0 @@
-/**
- * PANDA 3D SOFTWARE
- * Copyright (c) Carnegie Mellon University. All rights reserved.
- *
- * All use of this software is subject to the terms of the revised BSD
- * license. You should have received a copy of this license along
- * with this source code in a file named "LICENSE."
- *
- * @file cppClassTemplateParameter.h
- * @author drose
- * @date 1999-10-28
- */
-
-#ifndef CPPCLASSTEMPLATEPARAMETER_H
-#define CPPCLASSTEMPLATEPARAMETER_H
-
-#include "dtoolbase.h"
-
-#include "cppType.h"
-
-class CPPIdentifier;
-
-/**
- *
- */
-class CPPClassTemplateParameter : public CPPType {
-public:
- CPPClassTemplateParameter(CPPIdentifier *ident,
- CPPType *default_type = nullptr);
-
- virtual bool is_fully_specified() const;
- virtual void output(std::ostream &out, int indent_level, CPPScope *scope,
- bool complete) const;
- virtual SubType get_subtype() const;
-
- virtual CPPClassTemplateParameter *as_class_template_parameter();
-
- CPPIdentifier *_ident;
- CPPType *_default_type;
- bool _packed;
-
-protected:
- virtual bool is_equal(const CPPDeclaration *other) const;
- virtual bool is_less(const CPPDeclaration *other) const;
-};
-
-#endif
diff --git a/dtool/src/cppparser/cppClosureType.cxx b/dtool/src/cppparser/cppClosureType.cxx
deleted file mode 100644
index 5c201580f1..0000000000
--- a/dtool/src/cppparser/cppClosureType.cxx
+++ /dev/null
@@ -1,200 +0,0 @@
-/**
- * PANDA 3D SOFTWARE
- * Copyright (c) Carnegie Mellon University. All rights reserved.
- *
- * All use of this software is subject to the terms of the revised BSD
- * license. You should have received a copy of this license along
- * with this source code in a file named "LICENSE."
- *
- * @file cppClosureType.cxx
- * @author rdb
- * @date 2017-01-14
- */
-
-#include "cppClosureType.h"
-#include "cppParameterList.h"
-#include "cppExpression.h"
-
-/**
- *
- */
-CPPClosureType::
-CPPClosureType(CaptureType default_capture) :
- CPPFunctionType(nullptr, nullptr, 0),
- _default_capture(default_capture) {
-}
-
-/**
- *
- */
-CPPClosureType::
-CPPClosureType(const CPPClosureType ©) :
- CPPFunctionType(copy),
- _captures(copy._captures),
- _default_capture(copy._default_capture)
-{
-}
-
-/**
- *
- */
-void CPPClosureType::
-operator = (const CPPClosureType ©) {
- CPPFunctionType::operator = (copy);
- _captures = copy._captures;
- _default_capture = copy._default_capture;
-}
-
-/**
- * Adds a new capture to the beginning of the capture list.
- */
-void CPPClosureType::
-add_capture(std::string name, CaptureType type, CPPExpression *initializer) {
- if (type == CT_none) {
- if (name == "this") {
- type = CT_by_reference;
- } else {
- type = CT_by_value;
- }
- }
-
- Capture capture = {std::move(name), type, initializer};
- _captures.insert(_captures.begin(), std::move(capture));
-}
-
-/**
- * Returns true if this declaration is an actual, factual declaration, or
- * false if some part of the declaration depends on a template parameter which
- * has not yet been instantiated.
- */
-bool CPPClosureType::
-is_fully_specified() const {
- return CPPFunctionType::is_fully_specified();
-}
-
-/**
- * Returns true if the type is default-constructible.
- */
-bool CPPClosureType::
-is_default_constructible() const {
- return false;
-}
-
-/**
- * Returns true if the type is copy-constructible.
- */
-bool CPPClosureType::
-is_copy_constructible() const {
- return true;
-}
-
-/**
- * Returns true if the type is destructible.
- */
-bool CPPClosureType::
-is_destructible() const {
- return true;
-}
-
-/**
- *
- */
-void CPPClosureType::
-output(std::ostream &out, int indent_level, CPPScope *scope, bool complete) const {
- out.put('[');
-
- bool have_capture = false;
- switch (_default_capture) {
- case CT_none:
- break;
- case CT_by_reference:
- out.put('&');
- have_capture = true;
- break;
- case CT_by_value:
- out.put('=');
- have_capture = true;
- break;
- }
-
- Captures::const_iterator it;
- for (it = _captures.begin(); it != _captures.end(); ++it) {
- const Capture &capture = *it;
- if (have_capture) {
- out << ", ";
- }
- if (capture._name == "this") {
- if (capture._type == CT_by_value) {
- out.put('*');
- }
- } else {
- if (capture._type == CT_by_reference) {
- out.put('&');
- }
- }
- out << capture._name;
-
- if (capture._initializer != nullptr) {
- out << " = " << *capture._initializer;
- }
-
- have_capture = true;
- }
- out.put(']');
-
- if (_parameters != nullptr) {
- out.put('(');
- _parameters->output(out, scope, true, -1);
- out.put(')');
- }
-
- if (_flags & F_noexcept) {
- out << " noexcept";
- }
-
- if (!_attributes.is_empty()) {
- out << " " << _attributes;
- }
-
- if (_return_type != nullptr) {
- out << " -> ";
- _return_type->output(out, indent_level, scope, false);
- }
-
- out << " {}";
-}
-
-/**
- *
- */
-CPPDeclaration::SubType CPPClosureType::
-get_subtype() const {
- return ST_closure;
-}
-
-/**
- *
- */
-CPPClosureType *CPPClosureType::
-as_closure_type() {
- return this;
-}
-
-/**
- * Called by CPPDeclaration() to determine whether this type is equivalent to
- * another type of the same type.
- */
-bool CPPClosureType::
-is_equal(const CPPDeclaration *other) const {
- return (this == other);
-}
-
-
-/**
- * Called by CPPDeclaration() to determine whether this type should be ordered
- * before another type of the same type, in an arbitrary but fixed ordering.
- */
-bool CPPClosureType::
-is_less(const CPPDeclaration *other) const {
- return (this < other);
-}
diff --git a/dtool/src/cppparser/cppClosureType.h b/dtool/src/cppparser/cppClosureType.h
deleted file mode 100644
index 9e11a2f124..0000000000
--- a/dtool/src/cppparser/cppClosureType.h
+++ /dev/null
@@ -1,65 +0,0 @@
-/**
- * PANDA 3D SOFTWARE
- * Copyright (c) Carnegie Mellon University. All rights reserved.
- *
- * All use of this software is subject to the terms of the revised BSD
- * license. You should have received a copy of this license along
- * with this source code in a file named "LICENSE."
- *
- * @file cppClosureType.h
- * @author rdb
- * @date 2017-01-14
- */
-
-#ifndef CPPCLOSURETYPE_H
-#define CPPCLOSURETYPE_H
-
-#include "dtoolbase.h"
-
-#include "cppFunctionType.h"
-
-/**
- * The type of a lambda expression. This is like a function, but with
- * additional captures defined.
- */
-class CPPClosureType : public CPPFunctionType {
-public:
- enum CaptureType {
- CT_none,
- CT_by_reference,
- CT_by_value,
- };
-
- CPPClosureType(CaptureType default_capture = CT_none);
- CPPClosureType(const CPPClosureType ©);
- void operator = (const CPPClosureType ©);
-
- struct Capture {
- std::string _name;
- CaptureType _type;
- CPPExpression *_initializer;
- };
- typedef std::vector Captures;
- Captures _captures;
-
- CaptureType _default_capture;
-
- void add_capture(std::string name, CaptureType type, CPPExpression *initializer = nullptr);
-
- virtual bool is_fully_specified() const;
-
- virtual bool is_default_constructible() const;
- virtual bool is_copy_constructible() const;
- virtual bool is_destructible() const;
-
- virtual void output(std::ostream &out, int indent_level, CPPScope *scope,
- bool complete) const;
- virtual SubType get_subtype() const;
- virtual CPPClosureType *as_closure_type();
-
-protected:
- virtual bool is_equal(const CPPDeclaration *other) const;
- virtual bool is_less(const CPPDeclaration *other) const;
-};
-
-#endif
diff --git a/dtool/src/cppparser/cppCommentBlock.cxx b/dtool/src/cppparser/cppCommentBlock.cxx
deleted file mode 100644
index 46865ba44d..0000000000
--- a/dtool/src/cppparser/cppCommentBlock.cxx
+++ /dev/null
@@ -1,14 +0,0 @@
-/**
- * PANDA 3D SOFTWARE
- * Copyright (c) Carnegie Mellon University. All rights reserved.
- *
- * All use of this software is subject to the terms of the revised BSD
- * license. You should have received a copy of this license along
- * with this source code in a file named "LICENSE."
- *
- * @file cppCommentBlock.cxx
- * @author drose
- * @date 2000-08-15
- */
-
-#include "cppCommentBlock.h"
diff --git a/dtool/src/cppparser/cppCommentBlock.h b/dtool/src/cppparser/cppCommentBlock.h
deleted file mode 100644
index e31b3b6278..0000000000
--- a/dtool/src/cppparser/cppCommentBlock.h
+++ /dev/null
@@ -1,41 +0,0 @@
-/**
- * PANDA 3D SOFTWARE
- * Copyright (c) Carnegie Mellon University. All rights reserved.
- *
- * All use of this software is subject to the terms of the revised BSD
- * license. You should have received a copy of this license along
- * with this source code in a file named "LICENSE."
- *
- * @file cppCommentBlock.h
- * @author drose
- * @date 2000-08-15
- */
-
-#ifndef CPPCOMMENTBLOCK_H
-#define CPPCOMMENTBLOCK_H
-
-#include "dtoolbase.h"
-
-#include "cppFile.h"
-
-#include
-
-/**
- * This represents a comment appearing in the source code. The
- * CPPPreprocessor collects these, and saves the complete list of comments
- * encountered; it also stores a list of the comment blocks appearing before
- * each declaration.
- */
-class CPPCommentBlock {
-public:
- CPPFile _file;
- int _line_number;
- int _col_number;
- int _last_line;
- bool _c_style;
- std::string _comment;
-};
-
-typedef std::list CPPComments;
-
-#endif
diff --git a/dtool/src/cppparser/cppConstType.cxx b/dtool/src/cppparser/cppConstType.cxx
deleted file mode 100644
index 585f545b63..0000000000
--- a/dtool/src/cppparser/cppConstType.cxx
+++ /dev/null
@@ -1,240 +0,0 @@
-/**
- * PANDA 3D SOFTWARE
- * Copyright (c) Carnegie Mellon University. All rights reserved.
- *
- * All use of this software is subject to the terms of the revised BSD
- * license. You should have received a copy of this license along
- * with this source code in a file named "LICENSE."
- *
- * @file cppConstType.cxx
- * @author drose
- * @date 1999-10-28
- */
-
-#include "cppConstType.h"
-
-/**
- *
- */
-CPPConstType::
-CPPConstType(CPPType *wrapped_around) :
- CPPType(CPPFile()),
- _wrapped_around(wrapped_around)
-{
-}
-
-/**
- * Returns true if this declaration is an actual, factual declaration, or
- * false if some part of the declaration depends on a template parameter which
- * has not yet been instantiated.
- */
-bool CPPConstType::
-is_fully_specified() const {
- return CPPType::is_fully_specified() &&
- _wrapped_around->is_fully_specified();
-}
-
-/**
- *
- */
-CPPDeclaration *CPPConstType::
-substitute_decl(CPPDeclaration::SubstDecl &subst,
- CPPScope *current_scope, CPPScope *global_scope) {
- SubstDecl::const_iterator si = subst.find(this);
- if (si != subst.end()) {
- return (*si).second;
- }
-
- CPPConstType *rep = new CPPConstType(*this);
- rep->_wrapped_around =
- _wrapped_around->substitute_decl(subst, current_scope, global_scope)
- ->as_type();
-
- if (rep->_wrapped_around == _wrapped_around) {
- delete rep;
- rep = this;
- }
- rep = CPPType::new_type(rep)->as_const_type();
- subst.insert(SubstDecl::value_type(this, rep));
- return rep;
-}
-
-/**
- * If this CPPType object is a forward reference or other nonspecified
- * reference to a type that might now be known a real type, returns the real
- * type. Otherwise returns the type itself.
- */
-CPPType *CPPConstType::
-resolve_type(CPPScope *current_scope, CPPScope *global_scope) {
- CPPType *ptype = _wrapped_around->resolve_type(current_scope, global_scope);
-
- if (ptype != _wrapped_around) {
- CPPConstType *rep = new CPPConstType(*this);
- rep->_wrapped_around = ptype;
- return CPPType::new_type(rep);
- }
- return this;
-}
-
-/**
- * Returns true if the type, or any nested type within the type, is a
- * CPPTBDType and thus isn't fully determined right now. In this case,
- * calling resolve_type() may or may not resolve the type.
- */
-bool CPPConstType::
-is_tbd() const {
- return _wrapped_around->is_tbd();
-}
-
-/**
- * Returns true if the type is considered a fundamental type.
- */
-bool CPPConstType::
-is_fundamental() const {
- return _wrapped_around->is_fundamental();
-}
-
-/**
- * Returns true if the type is considered a standard layout type.
- */
-bool CPPConstType::
-is_standard_layout() const {
- return _wrapped_around->is_standard_layout();
-}
-
-/**
- * Returns true if the type is considered a Plain Old Data (POD) type.
- */
-bool CPPConstType::
-is_trivial() const {
- return _wrapped_around->is_trivial();
-}
-
-/**
- * Returns true if the type can be safely copied by memcpy or memmove.
- */
-bool CPPConstType::
-is_trivially_copyable() const {
- return _wrapped_around->is_trivially_copyable();
-}
-
-/**
- * Returns true if the type can be constructed using the given argument.
- */
-bool CPPConstType::
-is_constructible(const CPPType *given_type) const {
- return _wrapped_around->is_constructible(given_type);
-}
-
-/**
- * Returns true if the type is default-constructible.
- */
-bool CPPConstType::
-is_default_constructible() const {
- return _wrapped_around->is_default_constructible();
-}
-
-/**
- * Returns true if the type is copy-constructible.
- */
-bool CPPConstType::
-is_copy_constructible() const {
- return _wrapped_around->is_copy_constructible();
-}
-
-/**
- * Returns true if the type is destructible.
- */
-bool CPPConstType::
-is_destructible() const {
- return _wrapped_around->is_destructible();
-}
-
-/**
- * Returns true if variables of this type may be implicitly converted to
- * the other type.
- */
-bool CPPConstType::
-is_convertible_to(const CPPType *other) const {
- return _wrapped_around->is_convertible_to(other);
-}
-
-/**
- * This is a little more forgiving than is_equal(): it returns true if the
- * types appear to be referring to the same thing, even if they may have
- * different pointers or somewhat different definitions. It's useful for
- * parameter matching, etc.
- */
-bool CPPConstType::
-is_equivalent(const CPPType &other) const {
- const CPPConstType *ot = ((CPPType *)&other)->as_const_type();
- if (ot == nullptr) {
- return CPPType::is_equivalent(other);
- }
-
- return _wrapped_around->is_equivalent(*ot->_wrapped_around);
-}
-
-/**
- *
- */
-void CPPConstType::
-output(std::ostream &out, int indent_level, CPPScope *scope, bool complete) const {
- _wrapped_around->output(out, indent_level, scope, complete);
- out << " const";
-}
-
-/**
- * Formats a C++-looking line that defines an instance of the given type, with
- * the indicated name. In most cases this will be "type name", but some types
- * have special exceptions.
- */
-void CPPConstType::
-output_instance(std::ostream &out, int indent_level, CPPScope *scope,
- bool complete, const std::string &prename,
- const std::string &name) const {
- _wrapped_around->output_instance(out, indent_level, scope, complete,
- "const " + prename, name);
-}
-
-/**
- *
- */
-CPPDeclaration::SubType CPPConstType::
-get_subtype() const {
- return ST_const;
-}
-
-/**
- *
- */
-CPPConstType *CPPConstType::
-as_const_type() {
- return this;
-}
-
-
-/**
- * Called by CPPDeclaration() to determine whether this type is equivalent to
- * another type of the same type.
- */
-bool CPPConstType::
-is_equal(const CPPDeclaration *other) const {
- const CPPConstType *ot = ((CPPDeclaration *)other)->as_const_type();
- assert(ot != nullptr);
-
- return _wrapped_around == ot->_wrapped_around;
-}
-
-
-/**
- * Called by CPPDeclaration() to determine whether this type should be ordered
- * before another type of the same type, in an arbitrary but fixed ordering.
- */
-bool CPPConstType::
-is_less(const CPPDeclaration *other) const {
- const CPPConstType *ot = ((CPPDeclaration *)other)->as_const_type();
- assert(ot != nullptr);
-
- return _wrapped_around < ot->_wrapped_around;
-}
diff --git a/dtool/src/cppparser/cppConstType.h b/dtool/src/cppparser/cppConstType.h
deleted file mode 100644
index 81db17884a..0000000000
--- a/dtool/src/cppparser/cppConstType.h
+++ /dev/null
@@ -1,66 +0,0 @@
-/**
- * PANDA 3D SOFTWARE
- * Copyright (c) Carnegie Mellon University. All rights reserved.
- *
- * All use of this software is subject to the terms of the revised BSD
- * license. You should have received a copy of this license along
- * with this source code in a file named "LICENSE."
- *
- * @file cppConstType.h
- * @author drose
- * @date 1999-10-28
- */
-
-#ifndef CPPCONSTTYPE_H
-#define CPPCONSTTYPE_H
-
-#include "dtoolbase.h"
-
-#include "cppType.h"
-
-/**
- *
- */
-class CPPConstType : public CPPType {
-public:
- CPPConstType(CPPType *wrapped_around);
-
- CPPType *_wrapped_around;
-
- virtual bool is_fully_specified() const;
- virtual CPPDeclaration *substitute_decl(SubstDecl &subst,
- CPPScope *current_scope,
- CPPScope *global_scope);
-
- virtual CPPType *resolve_type(CPPScope *current_scope,
- CPPScope *global_scope);
-
- virtual bool is_tbd() const;
- virtual bool is_fundamental() const;
- virtual bool is_standard_layout() const;
- virtual bool is_trivial() const;
- virtual bool is_trivially_copyable() const;
- virtual bool is_constructible(const CPPType *type) const;
- virtual bool is_default_constructible() const;
- virtual bool is_copy_constructible() const;
- virtual bool is_destructible() const;
- virtual bool is_convertible_to(const CPPType *other) const;
- virtual bool is_equivalent(const CPPType &other) const;
-
- virtual void output(std::ostream &out, int indent_level, CPPScope *scope,
- bool complete) const;
- virtual void output_instance(std::ostream &out, int indent_level,
- CPPScope *scope,
- bool complete, const std::string &prename,
- const std::string &name) const;
-
- virtual SubType get_subtype() const;
-
- virtual CPPConstType *as_const_type();
-
-protected:
- virtual bool is_equal(const CPPDeclaration *other) const;
- virtual bool is_less(const CPPDeclaration *other) const;
-};
-
-#endif
diff --git a/dtool/src/cppparser/cppDeclaration.cxx b/dtool/src/cppparser/cppDeclaration.cxx
deleted file mode 100644
index ef7e87bdf6..0000000000
--- a/dtool/src/cppparser/cppDeclaration.cxx
+++ /dev/null
@@ -1,379 +0,0 @@
-/**
- * PANDA 3D SOFTWARE
- * Copyright (c) Carnegie Mellon University. All rights reserved.
- *
- * All use of this software is subject to the terms of the revised BSD
- * license. You should have received a copy of this license along
- * with this source code in a file named "LICENSE."
- *
- * @file cppDeclaration.cxx
- * @author drose
- * @date 1999-10-19
- */
-
-#include "cppDeclaration.h"
-#include "cppPreprocessor.h"
-
-/**
- *
- */
-CPPDeclaration::
-CPPDeclaration(const CPPFile &file, CPPAttributeList attr) :
- _file(file),
- _attributes(std::move(attr))
-{
- _vis = V_unknown;
- _template_scope = nullptr;
- _leading_comment = nullptr;
-}
-
-/**
- *
- */
-CPPDeclaration::
-CPPDeclaration(const CPPDeclaration ©) :
- _vis(copy._vis),
- _template_scope(copy._template_scope),
- _file(copy._file),
- _leading_comment(copy._leading_comment),
- _attributes(copy._attributes)
-{
-}
-
-/**
- *
- */
-CPPDeclaration &CPPDeclaration::
-operator = (const CPPDeclaration ©) {
- _vis = copy._vis;
- _template_scope = copy._template_scope;
- _file = copy._file;
- _leading_comment = copy._leading_comment;
- _attributes = copy._attributes;
- return *this;
-}
-
-/**
- *
- */
-bool CPPDeclaration::
-operator == (const CPPDeclaration &other) const {
- if (get_subtype() != other.get_subtype()) {
- return false;
- }
- return is_equal(&other);
-}
-
-/**
- *
- */
-bool CPPDeclaration::
-operator != (const CPPDeclaration &other) const {
- return !(*this == other);
-}
-
-/**
- *
- */
-bool CPPDeclaration::
-operator < (const CPPDeclaration &other) const {
- if (get_subtype() != other.get_subtype()) {
- return get_subtype() < other.get_subtype();
- }
- return is_less(&other);
-}
-
-/**
- * Returns true if this is a template declaration of some kind: a template
- * function or a template class, typically.
- */
-bool CPPDeclaration::
-is_template() const {
- return _template_scope != nullptr;
-}
-
-/**
- * If is_template(), above, returns true, this returns the CPPTemplateScope in
- * which this particular template declaration is defined. This scope includes
- * the information about the template parameters.
- */
-CPPTemplateScope *CPPDeclaration::
-get_template_scope() const {
- return _template_scope;
-}
-
-/**
- * Returns true if this declaration is an actual, factual declaration, or
- * false if some part of the declaration depends on a template parameter which
- * has not yet been instantiated.
- */
-bool CPPDeclaration::
-is_fully_specified() const {
- return !is_template();
-}
-
-/**
- *
- */
-CPPDeclaration *CPPDeclaration::
-instantiate(const CPPTemplateParameterList *,
- CPPScope *, CPPScope *,
- CPPPreprocessor *error_sink) const {
- if (error_sink != nullptr) {
- error_sink->warning("Ignoring template parameters");
- }
- return (CPPDeclaration *)this;
-}
-
-/**
- *
- */
-CPPDeclaration *CPPDeclaration::
-substitute_decl(SubstDecl &subst, CPPScope *, CPPScope *) {
- SubstDecl::const_iterator si = subst.find(this);
- if (si != subst.end()) {
- assert((*si).second != nullptr);
- return (*si).second;
- }
- return this;
-}
-
-/**
- *
- */
-void CPPDeclaration::
-output(std::ostream &out, int indent_level, CPPScope *scope, bool complete) const {
- out << _attributes;
-}
-
-/**
- *
- */
-CPPDeclaration::SubType CPPDeclaration::
-get_subtype() const {
- return ST_empty;
-}
-
-/**
- *
- */
-CPPInstance *CPPDeclaration::
-as_instance() {
- return nullptr;
-}
-
-/**
- *
- */
-CPPClassTemplateParameter *CPPDeclaration::
-as_class_template_parameter() {
- return nullptr;
-}
-
-/**
- *
- */
-CPPTypedefType *CPPDeclaration::
-as_typedef_type() {
- return nullptr;
-}
-
-/**
- *
- */
-CPPTypeDeclaration *CPPDeclaration::
-as_type_declaration() {
- return nullptr;
-}
-
-/**
- *
- */
-CPPExpression *CPPDeclaration::
-as_expression() {
- return nullptr;
-}
-
-/**
- *
- */
-CPPType *CPPDeclaration::
-as_type() {
- return nullptr;
-}
-
-/**
- *
- */
-CPPNamespace *CPPDeclaration::
-as_namespace() {
- return nullptr;
-}
-
-/**
- *
- */
-CPPUsing *CPPDeclaration::
-as_using() {
- return nullptr;
-}
-
-/**
- *
- */
-CPPSimpleType *CPPDeclaration::
-as_simple_type() {
- return nullptr;
-}
-
-/**
- *
- */
-CPPPointerType *CPPDeclaration::
-as_pointer_type() {
- return nullptr;
-}
-
-/**
- *
- */
-CPPReferenceType *CPPDeclaration::
-as_reference_type() {
- return nullptr;
-}
-
-/**
- *
- */
-CPPArrayType *CPPDeclaration::
-as_array_type() {
- return nullptr;
-}
-
-/**
- *
- */
-CPPConstType *CPPDeclaration::
-as_const_type() {
- return nullptr;
-}
-
-/**
- *
- */
-CPPFunctionType *CPPDeclaration::
-as_function_type() {
- return nullptr;
-}
-
-/**
- *
- */
-CPPFunctionGroup *CPPDeclaration::
-as_function_group() {
- return nullptr;
-}
-
-/**
- *
- */
-CPPExtensionType *CPPDeclaration::
-as_extension_type() {
- return nullptr;
-}
-
-/**
- *
- */
-CPPStructType *CPPDeclaration::
-as_struct_type() {
- return nullptr;
-}
-
-/**
- *
- */
-CPPEnumType *CPPDeclaration::
-as_enum_type() {
- return nullptr;
-}
-
-/**
- *
- */
-CPPTBDType *CPPDeclaration::
-as_tbd_type() {
- return nullptr;
-}
-
-/**
- *
- */
-CPPTypeProxy *CPPDeclaration::
-as_type_proxy() {
- return nullptr;
-}
-
-/**
- *
- */
-CPPMakeProperty *CPPDeclaration::
-as_make_property() {
- return nullptr;
-}
-
-/**
- *
- */
-CPPMakeSeq *CPPDeclaration::
-as_make_seq() {
- return nullptr;
-}
-
-/**
- *
- */
-CPPClosureType *CPPDeclaration::
-as_closure_type() {
- return nullptr;
-}
-
-/**
- * Called by CPPDeclaration to determine whether this type is equivalent to
- * another type of the same type.
- */
-bool CPPDeclaration::
-is_equal(const CPPDeclaration *other) const {
- return this == other;
-}
-
-/**
- * Called by CPPDeclaration to determine whether this type should be ordered
- * before another type of the same type, in an arbitrary but fixed ordering.
- */
-bool CPPDeclaration::
-is_less(const CPPDeclaration *other) const {
- return this < other;
-}
-
-
-std::ostream &
-operator << (std::ostream &out, const CPPDeclaration::SubstDecl &subst) {
- CPPDeclaration::SubstDecl::const_iterator it;
- for (it = subst.begin(); it != subst.end(); ++it) {
- out << " ";
- if (it->first == nullptr) {
- out << "(null)";
- } else {
- out << *(it->first);
- }
- out << " -> ";
- if (it->second == nullptr) {
- out << "(null)";
- } else {
- out << *(it->second);
- }
- out << "\n";
- }
- return out;
-}
diff --git a/dtool/src/cppparser/cppDeclaration.h b/dtool/src/cppparser/cppDeclaration.h
deleted file mode 100644
index 73c8fd49bb..0000000000
--- a/dtool/src/cppparser/cppDeclaration.h
+++ /dev/null
@@ -1,239 +0,0 @@
-/**
- * PANDA 3D SOFTWARE
- * Copyright (c) Carnegie Mellon University. All rights reserved.
- *
- * All use of this software is subject to the terms of the revised BSD
- * license. You should have received a copy of this license along
- * with this source code in a file named "LICENSE."
- *
- * @file cppDeclaration.h
- * @author drose
- * @date 1999-10-19
- */
-
-#ifndef CPPDECLARATION_H
-#define CPPDECLARATION_H
-
-#include "dtoolbase.h"
-
-#include "cppVisibility.h"
-#include "cppFile.h"
-#include "cppCommentBlock.h"
-#include "cppAttributeList.h"
-
-#include
-#include
-#include