diff --git a/.github/workflows/build_x86.yml b/.github/workflows/hosted_runners.yml
similarity index 83%
rename from .github/workflows/build_x86.yml
rename to .github/workflows/hosted_runners.yml
index f0d3aaf0da4..ab0fbb384c4 100644
--- a/.github/workflows/build_x86.yml
+++ b/.github/workflows/hosted_runners.yml
@@ -34,6 +34,7 @@ on:
env:
PACKAGING_REPO: https://github.com/osquery/osquery-packaging
PACKAGING_COMMIT: 8168fd7213b23447f1bfbe0b54d4e8b61730b08d
+ SUBMODULE_CACHE_VERSION: 1
# If the initial code sanity checks are passing, then one job
# per [`platform` * `build_type`] will start, building osquery
@@ -46,7 +47,7 @@ jobs:
runs-on: ubuntu-18.04
container:
- image: osquery/builder18.04:2c2b85cbd
+ image: osquery/builder18.04:a4961d234
options: --privileged --init -v /var/run/docker.sock:/var/run/docker.sock
steps:
@@ -103,7 +104,7 @@ jobs:
runs-on: ${{ matrix.os }}
container:
- image: osquery/builder18.04:2c2b85cbd
+ image: osquery/builder18.04:a4961d234
options: --privileged --init -v /var/run/docker.sock:/var/run/docker.sock
strategy:
@@ -139,10 +140,10 @@ jobs:
path: ${{ steps.build_paths.outputs.SOURCE }}/.git/modules
key: |
- gitmodules_${{ matrix.os }}_${{ github.sha }}
+ gitmodules_${{ matrix.os }}_${{env.SUBMODULE_CACHE_VERSION}}_${{ github.sha }}
restore-keys: |
- gitmodules_${{ matrix.os }}
+ gitmodules_${{ matrix.os }}_${{env.SUBMODULE_CACHE_VERSION}}
- name: Update the git submodules
working-directory: ${{ steps.build_paths.outputs.SOURCE }}
@@ -218,7 +219,7 @@ jobs:
runs-on: ${{ matrix.os }}
container:
- image: osquery/builder18.04:2c2b85cbd
+ image: osquery/builder18.04:a4961d234
options: --privileged --init -v /var/run/docker.sock:/var/run/docker.sock
strategy:
@@ -334,10 +335,10 @@ jobs:
path: ${{ steps.build_paths.outputs.SOURCE }}/.git/modules
key: |
- gitmodules_${{ matrix.os }}_${{ github.sha }}
+ gitmodules_${{ matrix.os }}_${{env.SUBMODULE_CACHE_VERSION}}_${{ github.sha }}
restore-keys: |
- gitmodules_${{ matrix.os }}
+ gitmodules_${{ matrix.os }}_${{env.SUBMODULE_CACHE_VERSION}}
- name: Update the git submodules
working-directory: ${{ steps.build_paths.outputs.SOURCE }}
@@ -502,7 +503,12 @@ jobs:
strategy:
matrix:
build_type: [Release, Debug]
- os: [macos-10.15]
+ architecture: [x86_64, arm64]
+ os: [macos-11]
+
+ exclude:
+ - build_type: Debug
+ architecture: arm64
steps:
- name: Select the build job count
@@ -548,23 +554,16 @@ jobs:
fetch-depth: 0
path: ${{ steps.build_paths.outputs.REL_SOURCE }}
- - name: Clone the osquery-packaging repository
- run: |
- git clone ${{ env.PACKAGING_REPO }} \
- ${{ steps.build_paths.outputs.PACKAGING }}
- cd ${{ steps.build_paths.outputs.PACKAGING }}
- git checkout ${{ env.PACKAGING_COMMIT }}
-
- name: Update the cache (ccache)
uses: actions/cache@v2
with:
path: ${{ steps.build_paths.outputs.CCACHE }}
key: |
- ccache_${{ matrix.os }}_${{ matrix.build_type }}_${{ github.sha }}
+ ccache_${{ matrix.os }}_${{ matrix.architecture }}_${{ matrix.build_type }}_${{ github.sha }}
restore-keys: |
- ccache_${{ matrix.os }}_${{ matrix.build_type }}
+ ccache_${{ matrix.os }}_${{ matrix.architecture }}_${{ matrix.build_type }}
- name: Update the cache (git submodules)
uses: actions/cache@v2
@@ -572,10 +571,10 @@ jobs:
path: ${{ steps.build_paths.outputs.SOURCE }}/.git/modules
key: |
- gitmodules_${{ matrix.os }}_${{ github.sha }}
+ gitmodules_${{ matrix.os }}_${{ matrix.architecture }}_${{env.SUBMODULE_CACHE_VERSION}}_${{ github.sha }}
restore-keys: |
- gitmodules_${{ matrix.os }}
+ gitmodules_${{ matrix.os }}_${{ matrix.architecture }}_${{env.SUBMODULE_CACHE_VERSION}}
- name: Update the cache (downloads)
uses: actions/cache@v2
@@ -583,10 +582,10 @@ jobs:
path: ${{ steps.build_paths.outputs.DOWNLOADS }}
key: |
- downloads_${{ matrix.os }}_${{ github.sha }}
+ downloads_${{ matrix.os }}_${{ matrix.architecture }}_${{ github.sha }}
restore-keys: |
- downloads_${{ matrix.os }}
+ downloads_${{ matrix.os }}_${{ matrix.architecture }}
- name: Update the git submodules
working-directory: ${{ steps.build_paths.outputs.SOURCE }}
@@ -595,7 +594,12 @@ jobs:
- name: Install build dependencies
run: |
- brew install ccache flex bison
+ brew install \
+ ccache \
+ flex \
+ bison \
+ coreutils \
+ gnu-sed
- name: Install tests dependencies
run: |
@@ -607,38 +611,29 @@ jobs:
thrift==0.11.0 \
osquery
- # We have to download CMake from the official website; a simple
- # caching mechanism has been implemented so that we don't keep
- # hitting the cmake.org website over and over again at each run
- name: Install CMake
shell: bash
run: |
- long_ver=3.17.5
- short_ver=$(echo ${long_ver} | cut -d '.' -f 1-2)
-
- folder_name="cmake-${long_ver}-Darwin-x86_64"
- filename="${folder_name}.tar.gz"
+ ${{ steps.build_paths.outputs.REL_SOURCE }}/tools/ci/scripts/macos/install_cmake.sh \
+ "${{ steps.build_paths.outputs.DOWNLOADS }}" \
+ "${{ steps.build_paths.outputs.INSTALL }}" \
+ "3.21.4"
- url="https://cmake.org/files/v${short_ver}/${filename}"
- local_path="${{ steps.build_paths.outputs.DOWNLOADS }}/${filename}"
+ - name: Select the Xcode version
+ shell: bash
+ id: xcode_selector
+ run: |
+ xcode_path="/Applications/Xcode_13.0.app/Contents/Developer"
+ echo ::set-output name=PATH::${path}
- if [[ ! -f "${local_path}" ]]; then
- wget "${url}" -O "${local_path}"
+ sudo xcode-select -s "${xcode_path}"
- ls -t ${{ steps.build_paths.outputs.DOWNLOADS }}/cmake* | tail -n +2 | while read archive_file ; do
- rm "${archive_file}"
- done
+ if [[ "${{ matrix.architecture }}" == "x86_64" ]] ; then
+ echo ::set-output name=DEPLOYMENT_TARGET::10.12
+ else
+ echo ::set-output name=DEPLOYMENT_TARGET::10.15
fi
- tar xf "${local_path}" \
- -C "${{ steps.build_paths.outputs.INSTALL }}"
-
- echo "${{ steps.build_paths.outputs.INSTALL }}/${folder_name}/CMake.app/Contents/bin" >> $GITHUB_PATH
-
- - name: Select the Xcode version
- run: |
- sudo xcode-select -s /Applications/Xcode_12.3.app/Contents/Developer
-
# We don't have enough space on the worker to actually generate all
# the debug symbols (osquery + dependencies), so we have a flag to
# disable them when running a Debug build
@@ -661,7 +656,8 @@ jobs:
run: |
cmake -G "Unix Makefiles" \
- -DCMAKE_OSX_DEPLOYMENT_TARGET=10.12 \
+ -DCMAKE_OSX_ARCHITECTURES="${{ matrix.architecture }}" \
+ -DCMAKE_OSX_DEPLOYMENT_TARGET="${{ steps.xcode_selector.outputs.DEPLOYMENT_TARGET }}" \
-DCMAKE_BUILD_TYPE:STRING="${{ matrix.build_type }}" \
-DOSQUERY_BUILD_TESTS=ON \
-DOSQUERY_NO_DEBUG_SYMBOLS=${{ steps.debug_symbols_settings.outputs.VALUE }} \
@@ -677,6 +673,7 @@ jobs:
cmake --build . -j ${{ steps.build_job_count.outputs.VALUE }}
- name: Run the tests
+ if: matrix.architecture == 'x86_64'
working-directory: ${{ steps.build_paths.outputs.BINARY }}
run: |
ctest --build-nocmake -V
@@ -694,61 +691,38 @@ jobs:
--target install \
-j ${{ steps.build_job_count.outputs.VALUE }}
- - name: Create the packages
- if: matrix.build_type == 'Release'
+ - name: Create the package data
working-directory: ${{ steps.build_paths.outputs.PACKAGE_BUILD }}
-
- shell: bash
-
run: |
- osquery_version=$(cd ${{ steps.build_paths.outputs.SOURCE }} && git describe --tags --always )
-
tar pcvzf package_data.tar.gz \
-C ${{ steps.build_paths.outputs.PACKAGE_DATA }} \
.
- package_format_list=( "productbuild" "TGZ" )
-
- for package_format in "${package_format_list[@]}" ; do
- cmake -DCMAKE_BUILD_TYPE=${{ matrix.build_type }} \
- -DCPACK_GENERATOR=${package_format} \
- -DOSQUERY_PACKAGE_VERSION=${osquery_version} \
- -DOSQUERY_DATA_PATH=${{ steps.build_paths.outputs.PACKAGE_DATA }} \
- ${{ steps.build_paths.outputs.PACKAGING }}
-
- cmake --build . \
- --target package
- done
-
- - name: Locate the packages
+ - name: Locate the package data
if: matrix.build_type == 'Release'
id: packages
shell: bash
run: |
echo ::set-output name=REL_UNSIGNED_RELEASE_PACKAGE_DATA_PATH::$(ls ${{ steps.build_paths.outputs.REL_PACKAGE_BUILD }}/package_data.tar.gz)
- echo ::set-output name=REL_UNSIGNED_RELEASE_PKG_PATH::$(ls ${{ steps.build_paths.outputs.REL_PACKAGE_BUILD }}/*.pkg)
- echo ::set-output name=REL_UNSIGNED_RELEASE_TGZ_PATH::$(ls ${{ steps.build_paths.outputs.REL_PACKAGE_BUILD }}/*.tar.gz | grep -v package_data)
- - name: Store the unsigned release package data artifact
+ - name: Store the ${{ matrix.architecture }} unsigned release package data artifact
if: matrix.build_type == 'Release'
uses: actions/upload-artifact@v1
with:
- name: macos_unsigned_release_package_data
+ name: macos_unsigned_release_package_data_${{ matrix.architecture }}
path: ${{ steps.packages.outputs.REL_UNSIGNED_RELEASE_PACKAGE_DATA_PATH }}
- - name: Store the unsigned release PKG artifact
- if: matrix.build_type == 'Release'
- uses: actions/upload-artifact@v1
- with:
- name: macos_unsigned_release_pkg
- path: ${{ steps.packages.outputs.REL_UNSIGNED_RELEASE_PKG_PATH }}
+ - name: Package the tests for the x86_64 macOS-10.15 worker
+ if: matrix.architecture == 'x86_64'
+ run: |
+ ( cd workspace && ${{ steps.build_paths.outputs.SOURCE }}/tools/ci/scripts/macos/package_tests.sh build macos_tests_${{ matrix.build_type }} )
- - name: Store the unsigned release TGZ artifact
- if: matrix.build_type == 'Release'
+ - name: Store the packaged tests for the x86_64 macOS-10.15 worker
+ if: matrix.architecture == 'x86_64'
uses: actions/upload-artifact@v1
with:
- name: macos_unsigned_release_tgz
- path: ${{ steps.packages.outputs.REL_UNSIGNED_RELEASE_TGZ_PATH }}
+ name: macos_tests_${{ matrix.build_type }}
+ path: workspace/macos_tests_${{ matrix.build_type }}.tar.gz
# Before we terminate this job, delete the build folder. The cache
# actions will require the disk space to create the archives.
@@ -759,6 +733,154 @@ jobs:
+ # This job takes the packaged tests (Release + Debug) from the big sur
+ # builder and runs them on Catalina
+ test_macos_catalina:
+ needs: build_macos
+
+ runs-on: macos-10.15
+
+ steps:
+ - name: Clone the osquery repository
+ uses: actions/checkout@v2
+ with:
+ fetch-depth: 0
+
+ - uses: actions/download-artifact@v2
+ with:
+ name: macos_tests_Release
+
+ - uses: actions/download-artifact@v2
+ with:
+ name: macos_tests_Debug
+
+ - name: Install tests dependencies
+ run: |
+ pip3 install setuptools \
+ pexpect==3.3 \
+ psutil \
+ timeout_decorator \
+ six \
+ thrift==0.11.0 \
+ osquery
+
+ - name: Install CMake
+ shell: bash
+ run: |
+ mkdir -p "workspace/downloads" \
+ "workspace/install"
+
+ ./tools/ci/scripts/macos/install_cmake.sh \
+ "workspace/downloads" \
+ "workspace/install" \
+ "3.21.4"
+
+ - name: Extract the tests
+ run: |
+ tar xzf macos_tests_Release.tar.gz
+ tar xzf macos_tests_Debug.tar.gz
+
+ - name: Run the Debug tests
+ run: |
+ ( cd macos_tests_Debug && ./run.sh )
+
+ - name: Run the Release tests
+ run: |
+ ( cd macos_tests_Release && ./run.sh )
+
+
+
+
+ # This job builds the universal macOS artifacts
+ build_universal_macos_artifacts:
+ needs: test_macos_catalina
+
+ runs-on: macos-11
+
+ steps:
+ - name: Clone the osquery repository
+ uses: actions/checkout@v2
+ with:
+ fetch-depth: 0
+
+ - name: Install CMake
+ shell: bash
+ run: |
+ mkdir -p "workspace/downloads" \
+ "workspace/install"
+
+ ./tools/ci/scripts/macos/install_cmake.sh \
+ "workspace/downloads" \
+ "workspace/install" \
+ "3.21.4"
+
+ - uses: actions/download-artifact@v2
+ with:
+ name: macos_unsigned_release_package_data_x86_64
+ path: macos_unsigned_release_package_data_x86_64
+
+ - uses: actions/download-artifact@v2
+ with:
+ name: macos_unsigned_release_package_data_arm64
+ path: macos_unsigned_release_package_data_arm64
+
+ - name: Create the universal package data
+ run: |
+ tools/ci/scripts/macos/build_universal_package_data.sh
+
+ - name: Store the universal unsigned release package data artifact
+ uses: actions/upload-artifact@v1
+ with:
+ name: macos_unsigned_release_package_data_universal
+ path: package_data.tar.gz
+
+ - name: Clone the osquery-packaging repository
+ run: |
+ git clone ${{ env.PACKAGING_REPO }} osquery-packaging
+
+ cd osquery-packaging
+ git checkout ${{ env.PACKAGING_COMMIT }}
+
+ - name: Create the packages
+ shell: bash
+ run: |
+ osquery_version=$(git describe --tags --always )
+ package_format_list=( "productbuild" "TGZ" )
+
+ for package_format in "${package_format_list[@]}" ; do
+ cmake -DCMAKE_BUILD_TYPE=Release \
+ -DCPACK_GENERATOR=${package_format} \
+ -DOSQUERY_PACKAGE_VERSION=${osquery_version} \
+ -DOSQUERY_DATA_PATH=$(pwd)/universal \
+ -S osquery-packaging \
+ -B package_build
+
+ cmake --build package_build \
+ --target package
+ done
+
+ - name: Locate the packages
+ id: packages
+ shell: bash
+ run: |
+ echo ::set-output name=REL_UNSIGNED_RELEASE_PKG_PATH::$(ls package_build/*.pkg)
+ echo ::set-output name=REL_UNSIGNED_RELEASE_TGZ_PATH::$(ls package_build/*.tar.gz)
+
+ - name: Store the PKG unsigned release packages
+ uses: actions/upload-artifact@v1
+ with:
+ name: macos_unsigned_pkg_universal
+ path: ${{ steps.packages.outputs.REL_UNSIGNED_RELEASE_PKG_PATH }}
+
+ - name: Store the TGZ unsigned release packages
+ uses: actions/upload-artifact@v1
+ with:
+ name: macos_unsigned_tgz_universal
+ path: ${{ steps.packages.outputs.REL_UNSIGNED_RELEASE_TGZ_PATH }}
+
+
+
+
# The Windows build will only start once we know that the code
# has been properly formatted
build_windows:
@@ -839,10 +961,10 @@ jobs:
path: ${{ steps.build_paths.outputs.SOURCE }}\.git\modules
key: |
- gitmodules_${{ matrix.os }}_${{ github.sha }}
+ gitmodules_${{ matrix.os }}_${{env.SUBMODULE_CACHE_VERSION}}_${{ github.sha }}
restore-keys: |
- gitmodules_${{ matrix.os }}
+ gitmodules_${{ matrix.os }}_${{env.SUBMODULE_CACHE_VERSION}}
- name: Update the cache (downloads)
uses: actions/cache@v2
@@ -902,10 +1024,10 @@ jobs:
working-directory: ${{ steps.build_paths.outputs.DOWNLOADS }}
shell: powershell
run: |
- $long_cmake_ver = "3.17.5"
+ $long_cmake_ver = "3.21.4"
$short_cmake_ver = $($long_cmake_ver.split(".")[0] + "." + $long_cmake_ver.split(".")[1])
- $folder_name = $("cmake-" + $long_cmake_ver + "-win64-x64")
+ $folder_name = $("cmake-" + $long_cmake_ver + "-windows-x86_64")
$archive_name = $($folder_name + ".zip")
$url = $("https://cmake.org/files/v" + $short_cmake_ver + "/" + $archive_name)
diff --git a/.github/workflows/build_aarch64.yml b/.github/workflows/self_hosted_runners.yml
similarity index 98%
rename from .github/workflows/build_aarch64.yml
rename to .github/workflows/self_hosted_runners.yml
index 86833a9db24..5c056b5516b 100644
--- a/.github/workflows/build_aarch64.yml
+++ b/.github/workflows/self_hosted_runners.yml
@@ -30,6 +30,7 @@ on:
env:
PACKAGING_REPO: https://github.com/osquery/osquery-packaging
PACKAGING_COMMIT: 8168fd7213b23447f1bfbe0b54d4e8b61730b08d
+ SUBMODULE_CACHE_VERSION: 1
# If the initial code sanity checks are passing, then one job
# per [`platform` * `build_type`] will start, building osquery
@@ -42,7 +43,7 @@ jobs:
runs-on: ubuntu-18.04
container:
- image: osquery/builder18.04:2c2b85cbd
+ image: osquery/builder18.04:a4961d234
options: --privileged --init -v /var/run/docker.sock:/var/run/docker.sock
steps:
@@ -160,7 +161,7 @@ jobs:
runs-on: ${{ matrix.os }}
container:
- image: osquery/builder18.04:2c2b85cbd
+ image: osquery/builder18.04:a4961d234
options: --privileged --init -v /var/run/docker.sock:/var/run/docker.sock
strategy:
@@ -266,10 +267,10 @@ jobs:
path: ${{ steps.build_paths.outputs.SOURCE }}/.git/modules
key: |
- gitmodules_${{ matrix.cache_key }}_${{ github.sha }}
+ gitmodules_${{ matrix.cache_key }}_${{env.SUBMODULE_CACHE_VERSION}}_${{ github.sha }}
restore-keys: |
- gitmodules_${{ matrix.cache_key }}
+ gitmodules_${{ matrix.cache_key }}_${{env.SUBMODULE_CACHE_VERSION}}
- name: Update the git submodules
working-directory: ${{ steps.build_paths.outputs.SOURCE }}
diff --git a/.gitmodules b/.gitmodules
index 401a4ba3cc0..a2204cc2c70 100644
--- a/.gitmodules
+++ b/.gitmodules
@@ -103,24 +103,9 @@
[submodule "libraries/cmake/source/gflags/src"]
path = libraries/cmake/source/gflags/src
url = https://github.com/gflags/gflags
-[submodule "libraries/cmake/source/aws-sdk-cpp/aws-c-common_src"]
- path = libraries/cmake/source/aws-sdk-cpp/aws-c-common_src
- url = https://github.com/awslabs/aws-c-common
-[submodule "libraries/cmake/source/aws-sdk-cpp/aws-c-event-stream_src"]
- path = libraries/cmake/source/aws-sdk-cpp/aws-c-event-stream_src
- url = https://github.com/awslabs/aws-c-event-stream
-[submodule "libraries/cmake/source/aws-sdk-cpp/aws-checksums_src"]
- path = libraries/cmake/source/aws-sdk-cpp/aws-checksums_src
- url = https://github.com/awslabs/aws-checksums
-[submodule "libraries/cmake/source/aws-sdk-cpp/aws-sdk-cpp_src"]
- path = libraries/cmake/source/aws-sdk-cpp/aws-sdk-cpp_src
- url = https://github.com/aws/aws-sdk-cpp
[submodule "libraries/cmake/source/boost/src"]
path = libraries/cmake/source/boost/src
url = https://github.com/boostorg/boost
-[submodule "libraries/cmake/source/icu/src"]
- path = libraries/cmake/source/icu/src
- url = https://github.com/unicode-org/icu
[submodule "libraries/cmake/source/augeas/gnulib/src"]
path = libraries/cmake/source/augeas/gnulib/src
url = https://github.com/osquery/third-party-gnulib
@@ -136,3 +121,45 @@
[submodule "libraries/cmake/source/libcap/src"]
path = libraries/cmake/source/libcap/src
url = https://kernel.googlesource.com/pub/scm/libs/libcap/libcap.git
+[submodule "libraries/cmake/source/aws-sdk-cpp/src/aws-crt-cpp"]
+ path = libraries/cmake/source/aws-sdk-cpp/src/aws-crt-cpp
+ url = https://github.com/awslabs/aws-crt-cpp.git
+[submodule "libraries/cmake/source/aws-sdk-cpp/src/aws-c-auth"]
+ path = libraries/cmake/source/aws-sdk-cpp/src/aws-c-auth
+ url = https://github.com/awslabs/aws-c-auth.git
+[submodule "libraries/cmake/source/aws-sdk-cpp/src/aws-c-cal"]
+ path = libraries/cmake/source/aws-sdk-cpp/src/aws-c-cal
+ url = https://github.com/awslabs/aws-c-cal.git
+[submodule "libraries/cmake/source/aws-sdk-cpp/src/aws-c-common"]
+ path = libraries/cmake/source/aws-sdk-cpp/src/aws-c-common
+ url = https://github.com/awslabs/aws-c-common.git
+[submodule "libraries/cmake/source/aws-sdk-cpp/src/aws-c-compression"]
+ path = libraries/cmake/source/aws-sdk-cpp/src/aws-c-compression
+ url = https://github.com/awslabs/aws-c-compression.git
+[submodule "libraries/cmake/source/aws-sdk-cpp/src/aws-c-event-stream"]
+ path = libraries/cmake/source/aws-sdk-cpp/src/aws-c-event-stream
+ url = https://github.com/awslabs/aws-c-event-stream.git
+[submodule "libraries/cmake/source/aws-sdk-cpp/src/aws-c-http"]
+ path = libraries/cmake/source/aws-sdk-cpp/src/aws-c-http
+ url = https://github.com/awslabs/aws-c-http.git
+[submodule "libraries/cmake/source/aws-sdk-cpp/src/aws-c-io"]
+ path = libraries/cmake/source/aws-sdk-cpp/src/aws-c-io
+ url = https://github.com/awslabs/aws-c-io.git
+[submodule "libraries/cmake/source/aws-sdk-cpp/src/aws-c-mqtt"]
+ path = libraries/cmake/source/aws-sdk-cpp/src/aws-c-mqtt
+ url = https://github.com/awslabs/aws-c-mqtt.git
+[submodule "libraries/cmake/source/aws-sdk-cpp/src/aws-c-s3"]
+ path = libraries/cmake/source/aws-sdk-cpp/src/aws-c-s3
+ url = https://github.com/awslabs/aws-c-s3.git
+[submodule "libraries/cmake/source/aws-sdk-cpp/src/aws-checksums"]
+ path = libraries/cmake/source/aws-sdk-cpp/src/aws-checksums
+ url = https://github.com/awslabs/aws-checksums.git
+[submodule "libraries/cmake/source/aws-sdk-cpp/src/aws-lc"]
+ path = libraries/cmake/source/aws-sdk-cpp/src/aws-lc
+ url = https://github.com/awslabs/aws-lc.git
+[submodule "libraries/cmake/source/aws-sdk-cpp/src/s2n"]
+ path = libraries/cmake/source/aws-sdk-cpp/src/s2n
+ url = https://github.com/awslabs/s2n.git
+[submodule "libraries/cmake/source/aws-sdk-cpp/src/aws-sdk-cpp"]
+ path = libraries/cmake/source/aws-sdk-cpp/src/aws-sdk-cpp
+ url = https://github.com/aws/aws-sdk-cpp
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 71018e8fa30..99bf0927731 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,5 +1,64 @@
# osquery Changelog
+
+## [5.1.0](https://github.com/osquery/osquery/releases/tag/5.1.0)
+
+[Git Commits](https://github.com/osquery/osquery/compare/5.0.1...5.1.0)
+
+Representing commits from 20 contributors! Thank you all.
+
+### New Features
+
+- Allow custom cpu limit duration for the watchdog ([#7348](https://github.com/osquery/osquery/pull/7348))
+- Support custom endpoints for AWS Kinesis and Firehose. ([#7317](https://github.com/osquery/osquery/pull/7317))
+
+### Table Changes
+
+- Add `docker_container_envs` table for access to docker container environment ([#7313](https://github.com/osquery/osquery/pull/7313))
+- `curl` table now returns peer certificates even if the TLS handshake does not complete ([#7349](https://github.com/osquery/osquery/pull/7349))
+
+### Under the Hood improvements
+
+- Allow tests and SDK to reset dispatcher state ([#7372](https://github.com/osquery/osquery/pull/7372))
+- Avoid string copies when looping through cron search dirs ([#7331](https://github.com/osquery/osquery/pull/7331))
+- Respect `read_max` flag when hashing using ssdeep ([#7367](https://github.com/osquery/osquery/pull/7367))
+
+### Bug Fixes
+
+- Detect when an extension has not started correctly on Windows ([#7355](https://github.com/osquery/osquery/pull/7355))
+- Fix crash #7353 when osquery captures kill syscall when not subscribed to them ([#7354](https://github.com/osquery/osquery/pull/7354))
+- Fix crash in AuditdNetlinkReader::configureAuditService when audit_add_rule_data returns an error ([#7337](https://github.com/osquery/osquery/pull/7337))
+- Fix crash when `windows_security_products` errors out ([#7401](https://github.com/osquery/osquery/pull/7401))
+- Fix for #7394 where cleanup of some event tables never occurs ([#7395](https://github.com/osquery/osquery/pull/7395))
+- Improve BPF publisher reliability ([#7302](https://github.com/osquery/osquery/pull/7302))
+- Lower log level of "executing distributed query" ([#7386](https://github.com/osquery/osquery/pull/7386))
+- Reduce excessive log messages from `authorized_keys` table implementation ([#7318](https://github.com/osquery/osquery/pull/7318))
+
+### Documentation
+
+- Add 5.0.1 CHANGELOG ([#7284](https://github.com/osquery/osquery/pull/7284))
+- Fix typo in Everything in SQL docs ([#7338](https://github.com/osquery/osquery/pull/7338))
+- Fix typo in SQL docs ([#7376](https://github.com/osquery/osquery/pull/7376))
+- Update GitHub issue templates ([#7361](https://github.com/osquery/osquery/pull/7361), [#7396](https://github.com/osquery/osquery/pull/7396))
+- Update installation guide to use newer macOS paths ([#7311](https://github.com/osquery/osquery/pull/7311))
+- Update macOS ESF documentation ([#7303](https://github.com/osquery/osquery/pull/7303))
+
+### Packs
+
+- Add Forcepoint Endpoint Chrome Extension detection to packs ([#7346](https://github.com/osquery/osquery/pull/7346))
+- Add `beurk` rootkit detection to packs ([#7345](https://github.com/osquery/osquery/pull/7345))
+
+### Build
+
+- Allow tests to reset the restarting state ([#7373](https://github.com/osquery/osquery/pull/7373))
+- Build librpm with ndb support ([#7294](https://github.com/osquery/osquery/pull/7294))
+- Customizable installation logic ([#7315](https://github.com/osquery/osquery/pull/7315))
+- Fix ASL test on macOS 11 and later ([#7320](https://github.com/osquery/osquery/pull/7320))
+- Restore query packs in Windows packaging ([#7388](https://github.com/osquery/osquery/pull/7388))
+- Skip deprecated ASL test when targeting macOS 10.13+ SDK ([#7358](https://github.com/osquery/osquery/pull/7358))
+- Update packaging commit to fix Linux symlinks ([#7404](https://github.com/osquery/osquery/pull/7404))
+- Update the CI Linux Docker image ([#7332](https://github.com/osquery/osquery/pull/7332))
+
## [5.0.1](https://github.com/osquery/osquery/releases/tag/5.0.1)
@@ -760,7 +819,7 @@ Thank you! :clap:
### Table Changes
- Added table `chrome_extension_content_scripts` to All Platforms ([#6140](https://github.com/osquery/osquery/pull/6140))
-- Added table `docker_container_fs_changes` to POSIX-compatible Plaforms ([#6178](https://github.com/osquery/osquery/pull/6178))
+- Added table `docker_container_fs_changes` to POSIX-compatible Platforms ([#6178](https://github.com/osquery/osquery/pull/6178))
- Added table `windows_security_center` to Microsoft Windows ([#6256](https://github.com/osquery/osquery/pull/6256))
- Added many new tables to Linux to query `lxd` ([#6249](https://github.com/osquery/osquery/pull/6249))
- Added table `screenlock` to Darwin (Apple OS X) ([#6243](https://github.com/osquery/osquery/pull/6243))
@@ -812,17 +871,17 @@ Thank you! :clap:
- Added table `mdls` to Darwin (Apple OS X) ([#4825](https://github.com/osquery/osquery/pull/4825))
- Added table `hvci_status` to Microsoft Windows ([#5426](https://github.com/osquery/osquery/pull/5426))
- Added table `ntfs_journal_events` to Microsoft Windows ([#5371](https://github.com/osquery/osquery/pull/5371))
-- Added table `docker_image_layers` to POSIX-compatible Plaforms ([#6154](https://github.com/osquery/osquery/pull/6154))
-- Added table `process_open_pipes` to POSIX-compatible Plaforms ([#6142](https://github.com/osquery/osquery/pull/6142))
+- Added table `docker_image_layers` to POSIX-compatible Platforms ([#6154](https://github.com/osquery/osquery/pull/6154))
+- Added table `process_open_pipes` to POSIX-compatible Platforms ([#6142](https://github.com/osquery/osquery/pull/6142))
- Added table `apparmor_profiles` to Ubuntu, CentOS ([#6138](https://github.com/osquery/osquery/pull/6138))
- Added table `selinux_settings` to Ubuntu, CentOS ([#6118](https://github.com/osquery/osquery/pull/6118))
- Added column `lock_status` (`INTEGER_TYPE`) to table `bitlocker_info` ([#6155](https://github.com/osquery/osquery/pull/6155))
- Added column `percentage_encrypted` (`INTEGER_TYPE`) to table `bitlocker_info` ([#6155](https://github.com/osquery/osquery/pull/6155))
- Added column `version` (`INTEGER_TYPE`) to table `bitlocker_info` ([#6155](https://github.com/osquery/osquery/pull/6155))
- Added column `optional_permissions` (`TEXT_TYPE`) to table `chrome_extensions` ([#6115](https://github.com/osquery/osquery/pull/6115))
-- Removed table `firefox_addons` from POSIX-compatible Plaforms ([#6200](https://github.com/osquery/osquery/pull/6200))
-- Removed table `ssh_configs` from POSIX-compatible Plaforms ([#6161](https://github.com/osquery/osquery/pull/6161))
-- Removed table `user_ssh_keys` from POSIX-compatible Plaforms ([#6161](https://github.com/osquery/osquery/pull/6161))
+- Removed table `firefox_addons` from POSIX-compatible Platforms ([#6200](https://github.com/osquery/osquery/pull/6200))
+- Removed table `ssh_configs` from POSIX-compatible Platforms ([#6161](https://github.com/osquery/osquery/pull/6161))
+- Removed table `user_ssh_keys` from POSIX-compatible Platforms ([#6161](https://github.com/osquery/osquery/pull/6161))
## [4.1.2](https://github.com/osquery/osquery/releases/tag/4.1.2)
diff --git a/CMakeLists.txt b/CMakeLists.txt
index e5a7ca55099..c3609e54a60 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -5,9 +5,7 @@
#
# SPDX-License-Identifier: (Apache-2.0 OR GPL-2.0-only)
-cmake_minimum_required(VERSION 3.17.5 FATAL_ERROR)
-
-cmake_policy(SET CMP0083 NEW)
+cmake_minimum_required(VERSION 3.21.4 FATAL_ERROR)
# toolchain.cmake needs to be included before project() because the former sets the compiler path for the custom toolchain,
# if the user specify it and the latter does compiler detection.
@@ -110,22 +108,19 @@ function(importLibraries)
"Linux:libudev"
"Linux,Darwin,Windows:libxml2"
"Linux,Darwin,Windows:linenoise-ng"
- "Linux,Darwin:lldpd"
"Linux,Darwin,Windows:lzma"
"Linux,Darwin:popt"
"Linux,Darwin,Windows:rapidjson"
"Linux,Darwin,Windows:rocksdb"
"Linux,Darwin,Windows:sleuthkit"
- "Linux,Darwin:smartmontools"
"Linux,Darwin,Windows:sqlite"
- "Linux,Darwin:ssdeep-cpp"
+ "Linux,Darwin:ssdeep"
"Linux,Darwin,Windows:thrift"
"Linux:util-linux"
"Linux,Darwin,Windows:yara"
"Linux,Darwin,Windows:zlib"
"Linux,Darwin,Windows:zstd"
"Linux,Darwin,Windows:openssl"
- "Linux,Darwin,Windows:icu"
"Linux:expat"
"Linux:dbus"
"Linux:libcap"
@@ -149,6 +144,14 @@ function(importLibraries)
)
endif()
+ # We want to remove support for lldpd and smartmontools, so skip support for M1
+ if(NOT DEFINED PLATFORM_MACOS OR NOT "${TARGET_PROCESSOR}" STREQUAL "aarch64")
+ list(APPEND library_descriptor_list
+ "Linux,Darwin:lldpd"
+ "Linux,Darwin:smartmontools"
+ )
+ endif()
+
foreach(library_descriptor ${library_descriptor_list})
# Expand the library descriptor
string(REPLACE ":" ";" library_descriptor "${library_descriptor}")
diff --git a/cmake/globals.cmake b/cmake/globals.cmake
index 0cf6c359061..b7fa4ab8076 100644
--- a/cmake/globals.cmake
+++ b/cmake/globals.cmake
@@ -33,10 +33,17 @@ elseif(CMAKE_SYSTEM_PROCESSOR STREQUAL "x86_64")
elseif(CMAKE_SYSTEM_PROCESSOR STREQUAL "aarch64")
# *nix AArch64
set(TARGET_PROCESSOR "aarch64")
+elseif(CMAKE_SYSTEM_PROCESSOR STREQUAL "arm64")
+ # Apple Silicon
+ set(TARGET_PROCESSOR "aarch64")
else()
message(FATAL_ERROR "Unsupported architecture ${CMAKE_SYSTEM_PROCESSOR}")
endif()
+if("arm64" IN_LIST CMAKE_OSX_ARCHITECTURES)
+ set(TARGET_PROCESSOR "aarch64")
+endif()
+
# TODO(alessandro): Add missing defines: PLATFORM_FREEBSD
if("${CMAKE_SYSTEM_NAME}" STREQUAL "Linux")
set(PLATFORM_POSIX 1)
@@ -77,6 +84,10 @@ if(DEFINED PLATFORM_WINDOWS)
enable_language(ASM_MASM)
endif()
+if(DEFINED PLATFORM_POSIX)
+ enable_language(ASM)
+endif()
+
if(DEFINED PLATFORM_MACOS)
enable_language(OBJCXX)
endif()
diff --git a/cmake/options.cmake b/cmake/options.cmake
index 7e10f6e397d..a380bc75a03 100644
--- a/cmake/options.cmake
+++ b/cmake/options.cmake
@@ -111,6 +111,14 @@ if("${THIRD_PARTY_REPOSITORY_URL}" STREQUAL "")
set(THIRD_PARTY_REPOSITORY_URL "https://s3.amazonaws.com/osquery-packages")
endif()
+# When building on macOS, make sure we are only building one architecture at a time
+if(PLATFORM_MACOS)
+ list(LENGTH CMAKE_OSX_ARCHITECTURES osx_arch_count)
+ if(osx_arch_count GREATER 1)
+ message(FATAL_ERROR "The CMAKE_OSX_ARCHITECTURES setting can only contain one architecture at a time")
+ endif()
+endif()
+
detectOsqueryVersion()
message(STATUS "osquery version: ${OSQUERY_VERSION_INTERNAL}")
diff --git a/cmake/utilities.cmake b/cmake/utilities.cmake
index acfc5d17664..f37154b8ba7 100644
--- a/cmake/utilities.cmake
+++ b/cmake/utilities.cmake
@@ -214,6 +214,15 @@ function(add_osquery_executable)
add_executable(${osquery_exe_name} ${osquery_exe_args})
+ if(DEFINED PLATFORM_MACOS)
+ getCleanedOsqueryVersion("OSQUERY_PLIST_VERSION")
+
+ configure_file(
+ "${CMAKE_SOURCE_DIR}/tools/deployment/macos_packaging/Info.plist.in"
+ "${CMAKE_SOURCE_DIR}/tools/deployment/macos_packaging/Info.plist"
+ )
+ endif()
+
if(DEFINED PLATFORM_WINDOWS)
set(OSQUERY_MANIFEST_TARGET_NAME "${osquery_exe_name}")
diff --git a/docs/wiki/deployment/configuration.md b/docs/wiki/deployment/configuration.md
index b7d43d30c4c..445a72346f8 100644
--- a/docs/wiki/deployment/configuration.md
+++ b/docs/wiki/deployment/configuration.md
@@ -631,8 +631,8 @@ See the [development documentation](../development/pubsub-framework.md) for more
Events are almost always tweaked via CLI flags and _options_ referenced above.
The configuration supports a method to explicitly allow and deny events subscribers.
-If you choose to explicitly allow subscribers, then all will be disabled except for those specificied in the allow list.
-If you choose to explicitly deny subscribers, then all will be enabled except for those specificied in the deny list.
+If you choose to explicitly allow subscribers, then all will be disabled except for those specified in the allow list.
+If you choose to explicitly deny subscribers, then all will be enabled except for those specified in the deny list.
You may want to explicitly disable subscribers if you are only interested in a single type of data produced by a general publisher.
diff --git a/docs/wiki/development/building.md b/docs/wiki/development/building.md
index 4b969ae51e2..addac4f5ba1 100644
--- a/docs/wiki/development/building.md
+++ b/docs/wiki/development/building.md
@@ -8,7 +8,7 @@ The supported compilers are: the osquery toolchain (LLVM/Clang 9.0.1) on Linux,
## Prerequisites
-Git (>= 2.14.0), CMake (>= 3.17.5), Python 3 are required to build. The rest of the dependencies are downloaded by CMake.
+Git (>= 2.14.0), CMake (>= 3.21.4), Python 3 are required to build. The rest of the dependencies are downloaded by CMake.
The default build type is `RelWithDebInfo` (optimizations active + debug symbols) and can be changed in the CMake configure phase by setting the `CMAKE_BUILD_TYPE` flag to `Release` or `Debug`.
@@ -38,11 +38,8 @@ sudo tar xvf osquery-toolchain-1.1.0-${ARCH}.tar.xz -C /usr/local
# Download and install a newer CMake.
# Afterward, verify that `/usr/local/bin` is in the `PATH` and comes before `/usr/bin`.
-# Please see the note below for building CMake on aarch64.
-if [[ "${ARCH}" = "x86_64" ]]; then
- wget https://cmake.org/files/v3.17/cmake-3.17.5-Linux-${ARCH}.tar.gz
- sudo tar xvf cmake-3.17.5-Linux-${ARCH}.tar.gz -C /usr/local --strip 1
-fi
+wget https://cmake.org/files/v3.21/cmake-3.21.4-linux-${ARCH}.tar.gz
+sudo tar xvf cmake-3.21.4-linux-${ARCH}.tar.gz -C /usr/local --strip 1
# Download source
git clone https://github.com/osquery/osquery
@@ -54,24 +51,6 @@ cmake -DOSQUERY_TOOLCHAIN_SYSROOT=/usr/local/osquery-toolchain ..
cmake --build . -j10 # where 10 is the number of parallel build jobs
```
-**CMake on aarch64**
-
-If you are building for aarch64 then please notes CMake > 3.19.3 includes aarch64 Linux binaries,
-however it also has a bug that prevents creating RPMs properly.
-
-Prefer to build and install CMake from source:
-
-```bash
-wget https://github.com/Kitware/CMake/releases/download/v3.17.5/cmake-3.17.5.tar.gz
-sudo apt install gcc g++ libssl-dev
-tar zxvf cmake-3.17.5.tar.gz
-pushd cmake-3.17.5/
-./bootstrap -- -DCMAKE_BUILD_TYPE:STRING=Release
-make -j`nproc`
-sudo make install
-popd
-```
-
## macOS
The current build of osquery supports deployment to the same set of macOS versions (macOS 10.12 and newer). _Building_ osquery from source on macOS now requires 10.15 Catalina.
@@ -134,7 +113,7 @@ After changing that key, reboot your build machine and re-attempt the build.
Note: It may be easier to install these prerequisites using [Chocolatey](https://chocolatey.org/).
-- [CMake](https://cmake.org/) (>= 3.17.5): the MSI installer is recommended. During installation, select the option to add it to the system `PATH` for all users. If there is any older version of CMake installed (e.g., using Chocolatey), uninstall that version first! Do not install CMake using the Visual Studio Installer, because it contains an older version than required.
+- [CMake](https://cmake.org/) (>= 3.21.4): the MSI installer is recommended. During installation, select the option to add it to the system `PATH` for all users. If there is any older version of CMake installed (e.g., using Chocolatey), uninstall that version first! Do not install CMake using the Visual Studio Installer, because it contains an older version than required.
- Visual Studio 2019 (2 options)
1. [Visual Studio 2019 Build Tools Installer](https://visualstudio.microsoft.com/thank-you-downloading-visual-studio/?sku=BuildTools&rel=16) (without Visual Studio): In the installer choose the "C++ build tools" workload, then on the right, under "Optional", select "MSVC v142 - VS 2019 C++", "Windows 10 SDK", and "C++ Clang tools for Windows".
2. [Visual Studio 2019 Community Installer](https://visualstudio.microsoft.com/thank-you-downloading-visual-studio/?sku=Community&rel=16): In the installer choose the "Desktop development with C++" workload, then on the right, under "Optional", select "MSVC v142 - VS 2019 C++", "Windows 10 SDK", and "C++ Clang tools for Windows".
@@ -377,7 +356,7 @@ git describe --tags --abbrev=0
set OSQUERY_VERSION=
```
-### Preparing to build the the osquery-packaging repository
+### Preparing to build the osquery-packaging repository
Pre-requisites (for RPM builds):
diff --git a/docs/wiki/installation/cli-flags.md b/docs/wiki/installation/cli-flags.md
index 619db5636bc..6d2a850dd74 100644
--- a/docs/wiki/installation/cli-flags.md
+++ b/docs/wiki/installation/cli-flags.md
@@ -124,10 +124,6 @@ A delay in seconds before the watchdog process starts enforcing memory and CPU u
By default the watchdog monitors extensions for improper shutdown, but NOT for performance and utilization issues. Enable this flag if you would like extensions to use the same CPU and memory limits as the osquery worker. This means that your extensions or third-party extensions may be asked to stop and restart during execution.
-`--utc=true`
-
-Attempt to convert all UNIX calendar times to UTC.
-
`--table_delay=0`
Add a microsecond delay between multiple table calls (when a table is used in a JOIN). A `200` microsecond delay will trade about 20% additional time for a reduced 5% CPU utilization.
diff --git a/libraries/cmake/README.md b/libraries/cmake/README.md
new file mode 100644
index 00000000000..8e42d1db956
--- /dev/null
+++ b/libraries/cmake/README.md
@@ -0,0 +1,117 @@
+This folder contains all the third party libraries that osquery needs.
+All the third party libraries in this folder are built from source.
+
+The ones under `source` use CMake as the build system and they are brought in as submodules.
+Their configuration logic is not run, so that their build is always the same, no matter the version of the platform they are built on.
+To achieve that, we generate and save their configuration artifacts in these folders, in a way that depends on each platform, but the general idea is that we want to have compatibility with the oldest version of the platform we want to support.
+
+Finally, since we don't want to run their configuration logic and build system when building osquery, we write a CMakeLists.txt which builds the sources for the library and hardcodes additional compiler options that are not included in the generated files, but that the original build system to the compiler invocation when building.
+
+The ones under `formula` (currently OpenSSL only) will still use CMake to build, but it passes through a different build system, which CMake executes. They can be submodules or, as in the case of OpenSSL, archives that CMake takes care to download.
+This is because reproducing that build system with CMake has proven to be too complex.
+Particular care is needed for these libraries, as with the `source` ones, so that they do not directly depend on features that are present only on the system they are currently built on.
+
+# Linux
+
+Beyond what previously described, we use a custom toolchain ([osquery-toolchain](https://github.com/osquery/osquery-toolchain)) that permits us to build osquery on either new distros or the oldest targeted distro (bar some bugs, see later).
+
+These are the current targeted versions:
+
+## x86
+
+CentOS 6.10
+
+```sh
+cat /etc/centos-release
+CentOS release 6.10 (Final)
+```
+
+```sh
+ldd --version
+ldd (GNU libc) 2.12
+[...]
+```
+
+```sh
+yum info glibc
+
+[...]
+Version: 2.12
+Release: 1.212.el6_10.3
+[...]
+```
+
+```sh
+uname -r
+2.6.32-754.18.2.el6.x86_64
+```
+
+## AArch64
+
+Ubuntu 16.04 on AWS Graviton
+
+```sh
+cat /etc/os-release
+
+[...]
+VERSION="16.04.7 LTS (Xenial Xerus)"
+[...]
+
+```
+
+```sh
+ldd --version
+ldd (Ubuntu GLIBC 2.23-0ubuntu11.3) 2.23
+[...]
+```
+
+```sh
+apt show libc-bin
+
+[...]
+Version: 2.23-0ubuntu11.3
+[...]
+```
+
+```sh
+uname -r
+4.15.0-1099-aws
+```
+
+## Troubleshooting
+
+There are some issues with the osquery-toolchain 1.1.0 when trying to use it on CentOS 6.10.
+Binaries like `as`, `ar`, etc need to be symlinked to their llvm counterpart, since the original ones are fully static and contain a glibc version that won't work on that old distribution, and will throw a `FATAL: kernel too old`.
+To fix this, supposing that the osquery-toolchain has been installed under `/usr/local/osquery-toolchain`, run the following commands:
+
+```sh
+cd /usr/local/osquery-toolchain/usr/bin
+
+rm as; ln -s llvm-as as
+rm ar; ln -s llvm-ar ar
+rm objcopy; ln -s llvm-objcopy objcopy
+rm ranlib; ln -s llvm-ranlib ranlib
+rm objdump; ln -s llvm-objdump objdump
+rm nm; ln -s llvm-nm nm
+rm strip; ln -s llvm-strip strip
+```
+
+
+# macOS
+
+The system compiler is used on Big Sur 11.6, XCode 13, SDK 11.3.
+Both x86 and M1 architectures are built on an x86 machine, using the toolchain ability to cross-compile.
+
+## x86
+
+The deployment target is 10.12
+
+## M1
+
+The deployment target is 10.15
+
+
+# Windows
+
+The system compiler is used on Windows 10, Visual Studio 2019.
+The SDK used currently is not fixed (depends on what's available on the CI or the developer machine), but in general the target we attempt to have is Windows 7.
diff --git a/libraries/cmake/formula/openssl/CMakeLists.txt b/libraries/cmake/formula/openssl/CMakeLists.txt
index b40fa0b1f6e..9bfea842a47 100644
--- a/libraries/cmake/formula/openssl/CMakeLists.txt
+++ b/libraries/cmake/formula/openssl/CMakeLists.txt
@@ -75,9 +75,21 @@ function(opensslMain)
)
endif()
+ if(TARGET_PROCESSOR STREQUAL "aarch64")
+ set(target_name
+ "darwin64-arm64-cc"
+ )
+ elseif(TARGET_PROCESSOR STREQUAL "x86_64")
+ set(target_name
+ "darwin64-x86_64-cc"
+ )
+ else()
+ message(FATAL_ERROR "Unsupported target processor")
+ endif()
+
set(configure_command
"${CMAKE_COMMAND}" -E env "CC=${CMAKE_C_COMPILER}" "AR=${CMAKE_AR}"
- perl ./Configure darwin64-x86_64-cc
+ perl ./Configure "${target_name}"
${common_options}
${OSQUERY_FORMULA_CFLAGS}
diff --git a/libraries/cmake/source/augeas/CMakeLists.txt b/libraries/cmake/source/augeas/CMakeLists.txt
index 0720ac6afcf..f5c2d903031 100644
--- a/libraries/cmake/source/augeas/CMakeLists.txt
+++ b/libraries/cmake/source/augeas/CMakeLists.txt
@@ -8,229 +8,74 @@
function(augeasMain)
set(library_root "${CMAKE_CURRENT_SOURCE_DIR}/src")
+ if(PLATFORM_LINUX)
+ set(generated_include_headers_path
+ "${CMAKE_CURRENT_SOURCE_DIR}/generated/linux/${TARGET_PROCESSOR}/config"
+ )
+
+ elseif(PLATFORM_WINDOWS)
+ set(generated_include_headers_path
+ "${CMAKE_CURRENT_SOURCE_DIR}/generated/windows/${TARGET_PROCESSOR}/config"
+ )
+
+ elseif(PLATFORM_MACOS)
+ set(generated_include_headers_path
+ "${CMAKE_CURRENT_SOURCE_DIR}/generated/macos/${TARGET_PROCESSOR}/config"
+ )
+ endif()
+
+ # Use the lexer and parser files built on macOS, since they were generated using
+ # the most recent versions of flex/bison
add_library(thirdparty_augeas
- "${library_root}/src/xml.c"
- "${library_root}/src/memory.c"
- "${library_root}/src/lens.c"
- "${library_root}/src/builtin.c"
- "${library_root}/src/ref.c"
- "${library_root}/src/transform.c"
+ "${library_root}/src/ast.c"
"${library_root}/src/augeas.c"
- "${library_root}/src/syntax.c"
"${library_root}/src/augrun.c"
- "${library_root}/src/fa.c"
- "${library_root}/src/internal.c"
- "${library_root}/src/info.c"
- "${library_root}/src/ast.c"
- "${library_root}/src/pathx.c"
- "${library_root}/src/regexp.c"
+ "${library_root}/src/builtin.c"
"${library_root}/src/errcode.c"
+ "${library_root}/src/fa.c"
"${library_root}/src/get.c"
+ "${library_root}/src/hash.c"
+ "${library_root}/src/info.c"
+ "${library_root}/src/internal.c"
"${library_root}/src/jmt.c"
+ "${library_root}/src/lens.c"
+ "${library_root}/src/memory.c"
+ "${library_root}/src/pathx.c"
"${library_root}/src/put.c"
- "${library_root}/src/hash.c"
- )
-
- # Flex and Bison are now required, since they are needed to build augeas.
- # We could generate those files locally and commit them if we don't want
- # to have them as hard dependencies
- if(DEFINED PLATFORM_MACOS)
- # We need to use Bison and Flex from homebrew because the ones provided by
- # Xcode are not compatible
- set(bison_executable_path "/usr/local/opt/bison/bin/bison")
- set(flex_executable_path "/usr/local/opt/flex/bin/flex")
-
- if(EXISTS "${bison_executable_path}")
- set(BISON_EXECUTABLE "${bison_executable_path}")
- endif()
-
- if(EXISTS "${flex_executable_path}")
- set(FLEX_EXECUTABLE "${flex_executable_path}")
- endif()
-
- if(NOT DEFINED BISON_EXECUTABLE OR NOT DEFINED FLEX_EXECUTABLE)
- message(FATAL_ERROR "Both bison and flex are required from homebrew; you can install them with `brew install flex bison`")
- endif()
-
- set(environment_modifier
- "/usr/local/opt/flex/bin:/usr/local/opt/bison/bin:$ENV{PATH}"
- )
-
- else()
- foreach(dependency FLEX BISON)
- find_package("${dependency}" REQUIRED)
- endforeach()
-
- set(environment_modifier
- "$ENV{PATH}"
- )
- endif()
-
- # Generate the parser
- set(augeas_parser_implementation_name "parser")
-
- set(augeas_parser_implementation "${CMAKE_CURRENT_BINARY_DIR}/${augeas_parser_implementation_name}.c")
- set(augeas_parser_definition "${library_root}/src/${augeas_parser_implementation_name}.y")
-
- add_custom_command(
- OUTPUT "${augeas_parser_implementation}"
- COMMAND "${CMAKE_COMMAND}" -E env PATH=${environment_modifier} "${BISON_EXECUTABLE}" "${augeas_parser_definition}" -o "${augeas_parser_implementation}"
- DEPENDS "${augeas_parser_definition}"
- WORKING_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}"
- COMMENT "Bison: Generarating augeas parser"
- VERBATIM
- )
-
- add_custom_target(
- augeas_parser_implementation_generator
- DEPENDS "${augeas_parser_implementation}"
- )
-
- # Generate the lexer
- set(augeas_lexer_implementation_name "lexer.c")
- set(augeas_lexer_definition "${library_root}/src/lexer.l")
-
- set(augeas_lexer_implementation "${CMAKE_CURRENT_BINARY_DIR}/${augeas_lexer_implementation_name}")
-
- add_custom_command(
- OUTPUT "${augeas_lexer_implementation}"
- COMMAND "${FLEX_EXECUTABLE}" -t "${augeas_lexer_definition}" > "${augeas_lexer_implementation_name}"
- DEPENDS "${augeas_lexer_definition}"
- WORKING_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}"
- COMMENT "Bison: Generarating augeas lexer"
- VERBATIM
- )
-
- add_custom_target(
- augeas_lexer_implementation_generator
- DEPENDS "${augeas_lexer_implementation}"
- )
-
- # Set up the dependencies
- add_dependencies(
- augeas_lexer_implementation_generator
- augeas_parser_implementation_generator
- )
-
- add_dependencies(thirdparty_augeas augeas_lexer_implementation_generator)
-
- # Add the newly generated files
- target_sources(thirdparty_augeas PRIVATE
- ${augeas_parser_implementation}
- ${augeas_lexer_implementation}
- )
-
- importGnulibOverrides()
-
- target_link_libraries(thirdparty_augeas PUBLIC
- thirdparty_libxml2
- )
+ "${library_root}/src/ref.c"
+ "${library_root}/src/regexp.c"
+ "${library_root}/src/syntax.c"
+ "${library_root}/src/transform.c"
+ "${library_root}/src/xml.c"
- target_link_libraries(thirdparty_augeas PRIVATE
- thirdparty_c_settings
- thirdparty_gnulib
+ "${CMAKE_CURRENT_SOURCE_DIR}/generated/macos/x86_64/code/lexer.c"
+ "${CMAKE_CURRENT_SOURCE_DIR}/generated/macos/x86_64/code/parser.c"
)
- if(DEFINED PLATFORM_MACOS)
- target_include_directories(thirdparty_augeas PRIVATE
- "${CMAKE_CURRENT_SOURCE_DIR}/config/macos"
- )
- elseif(DEFINED PLATFORM_LINUX)
- target_include_directories(thirdparty_augeas PRIVATE
- "${CMAKE_CURRENT_SOURCE_DIR}/config/linux"
- )
- endif()
-
target_include_directories(thirdparty_augeas PRIVATE
- "${CMAKE_CURRENT_SOURCE_DIR}/config"
- "${CMAKE_CURRENT_BINARY_DIR}"
"${library_root}/src"
+ "${generated_include_headers_path}"
)
target_include_directories(thirdparty_augeas SYSTEM INTERFACE
"${library_root}/src"
)
- set_property(GLOBAL PROPERTY AUGEAS_LENSES_FOLDER_PATH "${library_root}/lenses")
-endfunction()
-
-function(importGnulibOverrides)
- set(library_root "${CMAKE_CURRENT_SOURCE_DIR}/gnulib/src")
-
- if(DEFINED PLATFORM_LINUX)
- set(sources
- "${library_root}/lib/getfilecon.c"
- "${library_root}/lib/se-context.c"
- "${library_root}/lib/se-selinux.c"
- )
- elseif(DEFINED PLATFORM_MACOS)
- set(sources
- "${library_root}/lib/setlocale.c"
- "${library_root}/lib/argz.c"
- "${library_root}/lib/canonicalize-lgpl.c"
- "${library_root}/lib/regex.c"
- "${library_root}/lib/fnmatch.c"
- "${library_root}/lib/malloca.c"
- "${library_root}/lib/mempcpy.c"
- "${library_root}/lib/strstr.c"
- )
- endif()
-
- add_library(thirdparty_gnulib
- ${sources}
+ target_compile_definitions(thirdparty_augeas PRIVATE
+ HAVE_CONFIG_H
)
- if(DEFINED PLATFORM_MACOS)
- set(public_headers
- "${library_root}/lib/regex.h"
- "${library_root}/lib/canonicalize.h"
- "${library_root}/lib/malloca.h"
- )
-
- foreach(header ${public_headers})
- get_filename_component(filename "${header}" NAME)
-
- add_custom_command(
- OUTPUT "${CMAKE_CURRENT_BINARY_DIR}/gnulib/${filename}"
- COMMAND cmake -E copy "${header}" "${CMAKE_CURRENT_BINARY_DIR}/gnulib/${filename}"
- )
+ target_link_libraries(thirdparty_augeas
+ PRIVATE
+ thirdparty_c_settings
+ thirdparty_gnulib_headers
- list(APPEND public_headers_output "${CMAKE_CURRENT_BINARY_DIR}/gnulib/${filename}")
- endforeach()
-
- add_custom_target(thirdparty_gnulib_copy_public_headers DEPENDS ${public_headers_output})
- add_dependencies(thirdparty_gnulib thirdparty_gnulib_copy_public_headers)
-
- target_include_directories(thirdparty_gnulib PRIVATE
- "${CMAKE_CURRENT_SOURCE_DIR}/config/macos"
- "${CMAKE_CURRENT_SOURCE_DIR}/gnulib/generated/macos"
- )
-
- target_include_directories(thirdparty_gnulib SYSTEM INTERFACE
- "${CMAKE_CURRENT_BINARY_DIR}/gnulib"
- )
-
- target_include_directories(thirdparty_gnulib SYSTEM INTERFACE
- "${CMAKE_CURRENT_SOURCE_DIR}/gnulib/generated/macos"
- )
- elseif(DEFINED PLATFORM_LINUX)
- target_include_directories(thirdparty_gnulib PRIVATE
- "${CMAKE_CURRENT_SOURCE_DIR}/config/linux"
- "${CMAKE_CURRENT_SOURCE_DIR}/gnulib/generated/linux"
- )
-
- target_include_directories(thirdparty_gnulib SYSTEM INTERFACE
- "${CMAKE_CURRENT_SOURCE_DIR}/gnulib/generated/linux"
- )
- endif()
-
- target_include_directories(thirdparty_gnulib PRIVATE
- "${library_root}/lib"
+ PUBLIC
+ thirdparty_libxml2
+ thirdparty_gnulib_library
)
- target_link_libraries(thirdparty_gnulib PRIVATE
- thirdparty_c_settings
- )
+ set_property(GLOBAL PROPERTY AUGEAS_LENSES_FOLDER_PATH "${library_root}/lenses")
endfunction()
augeasMain()
diff --git a/libraries/cmake/source/augeas/README.md b/libraries/cmake/source/augeas/README.md
new file mode 100644
index 00000000000..bd025078a44
--- /dev/null
+++ b/libraries/cmake/source/augeas/README.md
@@ -0,0 +1,139 @@
+# Linux
+## Common
+
+Prepare the environment
+
+```bash
+export PATH="/opt/osquery-toolchain/usr/bin:${PATH}"
+export CFLAGS="--sysroot /opt/osquery-toolchain"
+export CXXFLAGS="${CFLAGS}"
+export CPPFLAGS="${CFLAGS}"
+export LDFLAGS="${CFLAGS}"
+export CC=clang
+```
+
+Disables tests, documentation and examples:
+
+```
+sed -i '/SUBDIRS += tests man doc examples/d' Makefile.am
+sed -i '/SUBDIRS += gnulib\/tests/d' Makefile.am
+```
+
+Disable the command line tools:
+
+```
+sed -i '/AUGEAS_CHECK_READLINE/d' configure.ac
+sed -i '/bin_PROGRAMS = augtool augparse augmatch/c\bin_PROGRAMS = ' src/Makefile.am
+```
+
+Pass the include headers of the libxml2 library we have in osquery (make sure to set the correct architecture!). Also set a fake library to pass the configuration step.
+
+```
+export LIBXML_CFLAGS="-I/home/ubuntu/osquery/libraries/cmake/source/libxml2/src/include -I/home/ubuntu/osquery/libraries/cmake/source/libxml2/generated/config/linux/x86_64 -I/home/ubuntu/osquery/libraries/cmake/source/libxml2/generated/version/linux/x86_64"
+export LIBXML_LIBS="-lpthreads"
+```
+
+Now configure the library
+
+```
+./autogen.sh \
+ --enable-static \
+ --enable-shared=no \
+ --without-selinux
+```
+
+Build the library
+
+```
+make -j $(nproc)
+```
+
+Copy the generated augeas files:
+
+ - `config.h`
+ - `datadir.h`
+ - `parser.c`
+ - `parser.h`
+ - `lexer.c`
+
+Copy the generated gnulib files:
+
+ - `config.h` (use the augeas one)
+ - All the files containing `AUTOGENERATED` under `lib`
+
+# macOS
+
+## x86_64
+
+```bash
+export CFLAGS="-isysroot /Applications/Xcode_13.0.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX11.3.sdk -mmacosx-version-min=10.12 -Wunguarded-availability-new"
+export LDFLAGS="${CFLAGS}"
+export CC=clang
+```
+
+Disables tests, documentation and examples:
+
+```
+gsed -i '/SUBDIRS += tests man doc examples/d' Makefile.am
+gsed -i '/SUBDIRS += gnulib\/tests/d' Makefile.am
+```
+
+Disable the command line tools:
+
+```
+gsed -i '/AUGEAS_CHECK_READLINE/d' configure.ac
+gsed -i '/bin_PROGRAMS = augtool augparse augmatch/c\bin_PROGRAMS = ' src/Makefile.am
+```
+
+Make sure we disable `open_memstream`, since it's only available in 10.12 and later
+
+```
+gsed -i 's/open_memstream//g' configure.ac
+```
+
+Pass the include headers of the libxml2 library we have in osquery (make sure to set the correct architecture!). Also set a fake library to pass the configuration step.
+
+```
+export LIBXML_CFLAGS="-I/Users/alessandro/Projects/osquery/libraries/cmake/source/libxml2/src/include -I/Users/alessandro/Projects/osquery/libraries/cmake/source/libxml2/generated/config/linux/x86_64 -I/Users/alessandro/Projects/osquery/libraries/cmake/source/libxml2/generated/version/linux/x86_64"
+export LIBXML_LIBS="-lpthreads"
+```
+
+Now configure the library
+
+```
+./autogen.sh \
+ --enable-static \
+ --enable-shared=no \
+ --without-selinux
+```
+
+Build the library
+
+```
+make -j $(nproc)
+```
+
+Copy the generated augeas files:
+
+ - `config.h`
+ - `datadir.h`
+ - `parser.c`
+ - `parser.h`
+ - `lexer.c`
+
+Copy the generated gnulib files:
+
+ - `config.h` (use the augeas one)
+ - All the files containing `AUTOGENERATED` under `lib`
+
+## m1
+
+Same as above, but use the following environment variables instead:
+
+```bash
+export CFLAGS="-isysroot /Applications/Xcode_13.0.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX11.3.sdk -mmacosx-version-min=10.15 -Wunguarded-availability-new -target arm64-apple-macos10.15"
+export LDFLAGS="${CFLAGS}"
+export CC=clang
+```
+
+Also pass this additional flag to `autogen.sh`: `--host=arm64-apple-macos10.15`
diff --git a/libraries/cmake/source/augeas/generated/linux/aarch64/code/lexer.c b/libraries/cmake/source/augeas/generated/linux/aarch64/code/lexer.c
new file mode 100644
index 00000000000..86edf38d3a6
--- /dev/null
+++ b/libraries/cmake/source/augeas/generated/linux/aarch64/code/lexer.c
@@ -0,0 +1,2362 @@
+#line 2 "lexer.c"
+/* config.h must precede flex's inclusion of
+ in order for its _GNU_SOURCE definition to take effect. */
+#include
+
+#line 7 "lexer.c"
+
+#define YY_INT_ALIGNED short int
+
+/* A lexical scanner generated by flex */
+
+#define FLEX_SCANNER
+#define YY_FLEX_MAJOR_VERSION 2
+#define YY_FLEX_MINOR_VERSION 6
+#define YY_FLEX_SUBMINOR_VERSION 0
+#if YY_FLEX_SUBMINOR_VERSION > 0
+#define FLEX_BETA
+#endif
+
+/* First, we deal with platform-specific or compiler-specific issues. */
+
+/* begin standard C headers. */
+#include
+#include
+#include
+#include
+
+/* end standard C headers. */
+
+/* flex integer type definitions */
+
+#ifndef FLEXINT_H
+#define FLEXINT_H
+
+/* C99 systems have . Non-C99 systems may or may not. */
+
+#if defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
+
+/* C99 says to define __STDC_LIMIT_MACROS before including stdint.h,
+ * if you want the limit (max/min) macros for int types.
+ */
+#ifndef __STDC_LIMIT_MACROS
+#define __STDC_LIMIT_MACROS 1
+#endif
+
+#include
+typedef int8_t flex_int8_t;
+typedef uint8_t flex_uint8_t;
+typedef int16_t flex_int16_t;
+typedef uint16_t flex_uint16_t;
+typedef int32_t flex_int32_t;
+typedef uint32_t flex_uint32_t;
+#else
+typedef signed char flex_int8_t;
+typedef short int flex_int16_t;
+typedef int flex_int32_t;
+typedef unsigned char flex_uint8_t;
+typedef unsigned short int flex_uint16_t;
+typedef unsigned int flex_uint32_t;
+
+/* Limits of integral types. */
+#ifndef INT8_MIN
+#define INT8_MIN (-128)
+#endif
+#ifndef INT16_MIN
+#define INT16_MIN (-32767-1)
+#endif
+#ifndef INT32_MIN
+#define INT32_MIN (-2147483647-1)
+#endif
+#ifndef INT8_MAX
+#define INT8_MAX (127)
+#endif
+#ifndef INT16_MAX
+#define INT16_MAX (32767)
+#endif
+#ifndef INT32_MAX
+#define INT32_MAX (2147483647)
+#endif
+#ifndef UINT8_MAX
+#define UINT8_MAX (255U)
+#endif
+#ifndef UINT16_MAX
+#define UINT16_MAX (65535U)
+#endif
+#ifndef UINT32_MAX
+#define UINT32_MAX (4294967295U)
+#endif
+
+#endif /* ! C99 */
+
+#endif /* ! FLEXINT_H */
+
+#ifdef __cplusplus
+
+/* The "const" storage-class-modifier is valid. */
+#define YY_USE_CONST
+
+#else /* ! __cplusplus */
+
+/* C99 requires __STDC__ to be defined as 1. */
+#if defined (__STDC__)
+
+#define YY_USE_CONST
+
+#endif /* defined (__STDC__) */
+#endif /* ! __cplusplus */
+
+#ifdef YY_USE_CONST
+#define yyconst const
+#else
+#define yyconst
+#endif
+
+/* Returned upon end-of-file. */
+#define YY_NULL 0
+
+/* Promotes a possibly negative, possibly signed char to an unsigned
+ * integer for use as an array index. If the signed char is negative,
+ * we want to instead treat it as an 8-bit unsigned char, hence the
+ * double cast.
+ */
+#define YY_SC_TO_UI(c) ((unsigned int) (unsigned char) c)
+
+/* An opaque pointer. */
+#ifndef YY_TYPEDEF_YY_SCANNER_T
+#define YY_TYPEDEF_YY_SCANNER_T
+typedef void* yyscan_t;
+#endif
+
+/* For convenience, these vars (plus the bison vars far below)
+ are macros in the reentrant scanner. */
+#define yyin yyg->yyin_r
+#define yyout yyg->yyout_r
+#define yyextra yyg->yyextra_r
+#define yyleng yyg->yyleng_r
+#define yytext yyg->yytext_r
+#define yylineno (YY_CURRENT_BUFFER_LVALUE->yy_bs_lineno)
+#define yycolumn (YY_CURRENT_BUFFER_LVALUE->yy_bs_column)
+#define yy_flex_debug yyg->yy_flex_debug_r
+
+/* Enter a start condition. This macro really ought to take a parameter,
+ * but we do it the disgusting crufty way forced on us by the ()-less
+ * definition of BEGIN.
+ */
+#define BEGIN yyg->yy_start = 1 + 2 *
+
+/* Translate the current start state into a value that can be later handed
+ * to BEGIN to return to the state. The YYSTATE alias is for lex
+ * compatibility.
+ */
+#define YY_START ((yyg->yy_start - 1) / 2)
+#define YYSTATE YY_START
+
+/* Action number for EOF rule of a given start state. */
+#define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1)
+
+/* Special action meaning "start processing a new file". */
+#define YY_NEW_FILE augl_restart(yyin ,yyscanner )
+
+#define YY_END_OF_BUFFER_CHAR 0
+
+/* Size of default input buffer. */
+#ifndef YY_BUF_SIZE
+#ifdef __ia64__
+/* On IA-64, the buffer size is 16k, not 8k.
+ * Moreover, YY_BUF_SIZE is 2*YY_READ_BUF_SIZE in the general case.
+ * Ditto for the __ia64__ case accordingly.
+ */
+#define YY_BUF_SIZE 32768
+#else
+#define YY_BUF_SIZE 16384
+#endif /* __ia64__ */
+#endif
+
+/* The state buf must be large enough to hold one state per character in the main buffer.
+ */
+#define YY_STATE_BUF_SIZE ((YY_BUF_SIZE + 2) * sizeof(yy_state_type))
+
+#ifndef YY_TYPEDEF_YY_BUFFER_STATE
+#define YY_TYPEDEF_YY_BUFFER_STATE
+typedef struct yy_buffer_state *YY_BUFFER_STATE;
+#endif
+
+#ifndef YY_TYPEDEF_YY_SIZE_T
+#define YY_TYPEDEF_YY_SIZE_T
+typedef size_t yy_size_t;
+#endif
+
+#define EOB_ACT_CONTINUE_SCAN 0
+#define EOB_ACT_END_OF_FILE 1
+#define EOB_ACT_LAST_MATCH 2
+
+ /* Note: We specifically omit the test for yy_rule_can_match_eol because it requires
+ * access to the local variable yy_act. Since yyless() is a macro, it would break
+ * existing scanners that call yyless() from OUTSIDE augl_lex.
+ * One obvious solution it to make yy_act a global. I tried that, and saw
+ * a 5% performance hit in a non-yylineno scanner, because yy_act is
+ * normally declared as a register variable-- so it is not worth it.
+ */
+ #define YY_LESS_LINENO(n) \
+ do { \
+ int yyl;\
+ for ( yyl = n; yyl < yyleng; ++yyl )\
+ if ( yytext[yyl] == '\n' )\
+ --yylineno;\
+ }while(0)
+ #define YY_LINENO_REWIND_TO(dst) \
+ do {\
+ const char *p;\
+ for ( p = yy_cp-1; p >= (dst); --p)\
+ if ( *p == '\n' )\
+ --yylineno;\
+ }while(0)
+
+/* Return all but the first "n" matched characters back to the input stream. */
+#define yyless(n) \
+ do \
+ { \
+ /* Undo effects of setting up yytext. */ \
+ int yyless_macro_arg = (n); \
+ YY_LESS_LINENO(yyless_macro_arg);\
+ *yy_cp = yyg->yy_hold_char; \
+ YY_RESTORE_YY_MORE_OFFSET \
+ yyg->yy_c_buf_p = yy_cp = yy_bp + yyless_macro_arg - YY_MORE_ADJ; \
+ YY_DO_BEFORE_ACTION; /* set up yytext again */ \
+ } \
+ while ( 0 )
+
+#define unput(c) yyunput( c, yyg->yytext_ptr , yyscanner )
+
+#ifndef YY_STRUCT_YY_BUFFER_STATE
+#define YY_STRUCT_YY_BUFFER_STATE
+struct yy_buffer_state
+ {
+ FILE *yy_input_file;
+
+ char *yy_ch_buf; /* input buffer */
+ char *yy_buf_pos; /* current position in input buffer */
+
+ /* Size of input buffer in bytes, not including room for EOB
+ * characters.
+ */
+ yy_size_t yy_buf_size;
+
+ /* Number of characters read into yy_ch_buf, not including EOB
+ * characters.
+ */
+ int yy_n_chars;
+
+ /* Whether we "own" the buffer - i.e., we know we created it,
+ * and can realloc() it to grow it, and should free() it to
+ * delete it.
+ */
+ int yy_is_our_buffer;
+
+ /* Whether this is an "interactive" input source; if so, and
+ * if we're using stdio for input, then we want to use getc()
+ * instead of fread(), to make sure we stop fetching input after
+ * each newline.
+ */
+ int yy_is_interactive;
+
+ /* Whether we're considered to be at the beginning of a line.
+ * If so, '^' rules will be active on the next match, otherwise
+ * not.
+ */
+ int yy_at_bol;
+
+ int yy_bs_lineno; /**< The line count. */
+ int yy_bs_column; /**< The column count. */
+
+ /* Whether to try to fill the input buffer when we reach the
+ * end of it.
+ */
+ int yy_fill_buffer;
+
+ int yy_buffer_status;
+
+#define YY_BUFFER_NEW 0
+#define YY_BUFFER_NORMAL 1
+ /* When an EOF's been seen but there's still some text to process
+ * then we mark the buffer as YY_EOF_PENDING, to indicate that we
+ * shouldn't try reading from the input source any more. We might
+ * still have a bunch of tokens to match, though, because of
+ * possible backing-up.
+ *
+ * When we actually see the EOF, we change the status to "new"
+ * (via augl_restart()), so that the user can continue scanning by
+ * just pointing yyin at a new input file.
+ */
+#define YY_BUFFER_EOF_PENDING 2
+
+ };
+#endif /* !YY_STRUCT_YY_BUFFER_STATE */
+
+/* We provide macros for accessing buffer states in case in the
+ * future we want to put the buffer states in a more general
+ * "scanner state".
+ *
+ * Returns the top of the stack, or NULL.
+ */
+#define YY_CURRENT_BUFFER ( yyg->yy_buffer_stack \
+ ? yyg->yy_buffer_stack[yyg->yy_buffer_stack_top] \
+ : NULL)
+
+/* Same as previous macro, but useful when we know that the buffer stack is not
+ * NULL or when we need an lvalue. For internal use only.
+ */
+#define YY_CURRENT_BUFFER_LVALUE yyg->yy_buffer_stack[yyg->yy_buffer_stack_top]
+
+void augl_restart (FILE *input_file ,yyscan_t yyscanner );
+void augl__switch_to_buffer (YY_BUFFER_STATE new_buffer ,yyscan_t yyscanner );
+YY_BUFFER_STATE augl__create_buffer (FILE *file,int size ,yyscan_t yyscanner );
+void augl__delete_buffer (YY_BUFFER_STATE b ,yyscan_t yyscanner );
+void augl__flush_buffer (YY_BUFFER_STATE b ,yyscan_t yyscanner );
+void augl_push_buffer_state (YY_BUFFER_STATE new_buffer ,yyscan_t yyscanner );
+void augl_pop_buffer_state (yyscan_t yyscanner );
+
+static void augl_ensure_buffer_stack (yyscan_t yyscanner );
+static void augl__load_buffer_state (yyscan_t yyscanner );
+static void augl__init_buffer (YY_BUFFER_STATE b,FILE *file ,yyscan_t yyscanner );
+
+#define YY_FLUSH_BUFFER augl__flush_buffer(YY_CURRENT_BUFFER ,yyscanner)
+
+YY_BUFFER_STATE augl__scan_buffer (char *base,yy_size_t size ,yyscan_t yyscanner );
+YY_BUFFER_STATE augl__scan_string (yyconst char *yy_str ,yyscan_t yyscanner );
+YY_BUFFER_STATE augl__scan_bytes (yyconst char *bytes,yy_size_t len ,yyscan_t yyscanner );
+
+void *augl_alloc (yy_size_t ,yyscan_t yyscanner );
+void *augl_realloc (void *,yy_size_t ,yyscan_t yyscanner );
+void augl_free (void * ,yyscan_t yyscanner );
+
+#define yy_new_buffer augl__create_buffer
+
+#define yy_set_interactive(is_interactive) \
+ { \
+ if ( ! YY_CURRENT_BUFFER ){ \
+ augl_ensure_buffer_stack (yyscanner); \
+ YY_CURRENT_BUFFER_LVALUE = \
+ augl__create_buffer(yyin,YY_BUF_SIZE ,yyscanner); \
+ } \
+ YY_CURRENT_BUFFER_LVALUE->yy_is_interactive = is_interactive; \
+ }
+
+#define yy_set_bol(at_bol) \
+ { \
+ if ( ! YY_CURRENT_BUFFER ){\
+ augl_ensure_buffer_stack (yyscanner); \
+ YY_CURRENT_BUFFER_LVALUE = \
+ augl__create_buffer(yyin,YY_BUF_SIZE ,yyscanner); \
+ } \
+ YY_CURRENT_BUFFER_LVALUE->yy_at_bol = at_bol; \
+ }
+
+#define YY_AT_BOL() (YY_CURRENT_BUFFER_LVALUE->yy_at_bol)
+
+/* Begin user sect3 */
+
+#define augl_wrap(yyscanner) (/*CONSTCOND*/1)
+#define YY_SKIP_YYWRAP
+
+typedef unsigned char YY_CHAR;
+
+typedef int yy_state_type;
+
+#define yytext_ptr yytext_r
+
+static yy_state_type yy_get_previous_state (yyscan_t yyscanner );
+static yy_state_type yy_try_NUL_trans (yy_state_type current_state ,yyscan_t yyscanner);
+static int yy_get_next_buffer (yyscan_t yyscanner );
+#if defined(__GNUC__) && __GNUC__ >= 3
+__attribute__((__noreturn__))
+#endif
+static void yy_fatal_error (yyconst char msg[] ,yyscan_t yyscanner );
+
+/* Done after the current pattern has been matched and before the
+ * corresponding action - sets up yytext.
+ */
+#define YY_DO_BEFORE_ACTION \
+ yyg->yytext_ptr = yy_bp; \
+ yyleng = (size_t) (yy_cp - yy_bp); \
+ yyg->yy_hold_char = *yy_cp; \
+ *yy_cp = '\0'; \
+ yyg->yy_c_buf_p = yy_cp;
+
+#define YY_NUM_RULES 29
+#define YY_END_OF_BUFFER 30
+/* This struct is not used in this scanner,
+ but its presence is necessary. */
+struct yy_trans_info
+ {
+ flex_int32_t yy_verify;
+ flex_int32_t yy_nxt;
+ };
+static yyconst flex_int16_t yy_accept[95] =
+ { 0,
+ 1, 1, 1, 1, 30, 25, 1, 2, 25, 25,
+ 7, 7, 7, 25, 23, 22, 22, 22, 22, 22,
+ 22, 22, 22, 22, 22, 28, 1, 28, 28, 28,
+ 1, 2, 3, 0, 4, 0, 24, 20, 0, 6,
+ 0, 0, 23, 22, 22, 22, 22, 14, 22, 22,
+ 22, 22, 22, 22, 26, 27, 0, 5, 21, 22,
+ 22, 17, 22, 10, 22, 18, 22, 22, 22, 21,
+ 22, 22, 13, 0, 22, 22, 22, 16, 19, 22,
+ 0, 22, 22, 22, 22, 0, 8, 12, 11, 22,
+ 0, 15, 9, 0
+
+ } ;
+
+static yyconst YY_CHAR yy_ec[256] =
+ { 0,
+ 1, 1, 1, 1, 1, 1, 1, 1, 2, 3,
+ 1, 1, 4, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 2, 1, 5, 1, 1, 1, 1, 1, 6,
+ 7, 8, 9, 1, 10, 11, 12, 13, 13, 13,
+ 13, 13, 13, 13, 13, 13, 13, 9, 9, 1,
+ 9, 14, 9, 1, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 9, 16, 9, 1, 17, 1, 18, 17, 19, 20,
+
+ 21, 22, 23, 17, 24, 17, 17, 25, 26, 27,
+ 28, 29, 17, 30, 31, 32, 33, 17, 17, 34,
+ 17, 17, 9, 9, 9, 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
+ } ;
+
+static yyconst YY_CHAR yy_meta[35] =
+ { 0,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 2, 1, 3, 1, 3, 1, 4, 4, 4, 4,
+ 4, 4, 4, 4, 4, 4, 4, 4, 4, 4,
+ 4, 4, 4, 4
+ } ;
+
+static yyconst flex_uint16_t yy_base[102] =
+ { 0,
+ 0, 0, 33, 40, 134, 135, 131, 129, 128, 33,
+ 122, 135, 115, 35, 117, 0, 23, 106, 99, 104,
+ 96, 90, 101, 89, 99, 135, 117, 115, 109, 109,
+ 113, 111, 109, 45, 135, 0, 135, 135, 41, 88,
+ 0, 0, 100, 0, 78, 77, 76, 0, 27, 87,
+ 74, 82, 74, 72, 135, 135, 99, 135, 0, 80,
+ 72, 0, 68, 96, 64, 0, 75, 71, 62, 0,
+ 63, 67, 0, 38, 66, 56, 62, 0, 0, 60,
+ 46, 45, 36, 41, 42, 39, 0, 0, 0, 35,
+ 60, 0, 135, 135, 68, 72, 76, 79, 81, 48,
+
+ 83
+ } ;
+
+static yyconst flex_int16_t yy_def[102] =
+ { 0,
+ 94, 1, 95, 95, 94, 94, 94, 94, 94, 96,
+ 94, 94, 94, 97, 98, 99, 99, 99, 99, 99,
+ 99, 99, 99, 99, 99, 94, 94, 94, 94, 94,
+ 94, 94, 94, 96, 94, 96, 94, 94, 97, 94,
+ 97, 100, 98, 99, 99, 99, 99, 99, 99, 99,
+ 99, 99, 99, 99, 94, 94, 94, 94, 101, 99,
+ 99, 99, 99, 99, 99, 99, 99, 99, 99, 101,
+ 99, 99, 99, 94, 99, 99, 99, 99, 99, 99,
+ 94, 99, 99, 99, 99, 94, 99, 99, 99, 99,
+ 94, 99, 94, 0, 94, 94, 94, 94, 94, 94,
+
+ 94
+ } ;
+
+static yyconst flex_uint16_t yy_nxt[170] =
+ { 0,
+ 6, 7, 8, 9, 10, 11, 12, 12, 12, 13,
+ 12, 14, 6, 6, 15, 6, 16, 17, 16, 16,
+ 16, 16, 18, 19, 20, 21, 16, 16, 22, 23,
+ 24, 25, 16, 16, 27, 8, 28, 35, 29, 74,
+ 30, 27, 8, 28, 45, 29, 40, 30, 36, 35,
+ 41, 59, 40, 63, 92, 46, 41, 91, 64, 90,
+ 36, 93, 93, 89, 88, 87, 86, 81, 26, 26,
+ 26, 26, 34, 34, 34, 34, 39, 39, 39, 39,
+ 43, 43, 43, 44, 44, 70, 70, 85, 84, 83,
+ 82, 80, 79, 78, 77, 76, 75, 74, 73, 72,
+
+ 71, 33, 69, 68, 67, 66, 65, 62, 61, 60,
+ 42, 58, 57, 32, 31, 56, 55, 33, 31, 54,
+ 53, 52, 51, 50, 49, 48, 47, 42, 38, 37,
+ 33, 32, 31, 94, 5, 94, 94, 94, 94, 94,
+ 94, 94, 94, 94, 94, 94, 94, 94, 94, 94,
+ 94, 94, 94, 94, 94, 94, 94, 94, 94, 94,
+ 94, 94, 94, 94, 94, 94, 94, 94, 94
+ } ;
+
+static yyconst flex_int16_t yy_chk[170] =
+ { 0,
+ 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, 3, 3, 10, 3, 74,
+ 3, 4, 4, 4, 17, 4, 14, 4, 10, 34,
+ 14, 100, 39, 49, 90, 17, 39, 86, 49, 85,
+ 34, 91, 91, 84, 83, 82, 81, 74, 95, 95,
+ 95, 95, 96, 96, 96, 96, 97, 97, 97, 97,
+ 98, 98, 98, 99, 99, 101, 101, 80, 77, 76,
+ 75, 72, 71, 69, 68, 67, 65, 64, 63, 61,
+
+ 60, 57, 54, 53, 52, 51, 50, 47, 46, 45,
+ 43, 40, 33, 32, 31, 30, 29, 28, 27, 25,
+ 24, 23, 22, 21, 20, 19, 18, 15, 13, 11,
+ 9, 8, 7, 5, 94, 94, 94, 94, 94, 94,
+ 94, 94, 94, 94, 94, 94, 94, 94, 94, 94,
+ 94, 94, 94, 94, 94, 94, 94, 94, 94, 94,
+ 94, 94, 94, 94, 94, 94, 94, 94, 94
+ } ;
+
+/* Table of booleans, true if rule could match eol. */
+static yyconst flex_int32_t yy_rule_can_match_eol[30] =
+ { 0,
+0, 1, 1, 1, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, };
+
+/* The intent behind this definition is that it'll catch
+ * any uses of REJECT which flex missed.
+ */
+#define REJECT reject_used_but_not_detected
+#define yymore() yymore_used_but_not_detected
+#define YY_MORE_ADJ 0
+#define YY_RESTORE_YY_MORE_OFFSET
+#line 1 "lexer.l"
+/* Scanner for config specs -*- C -*- */
+#define YY_NO_INPUT 1
+
+#line 16 "lexer.l"
+#include "syntax.h"
+#include "errcode.h"
+
+typedef struct info YYLTYPE;
+#define YYLTYPE_IS_DECLARED 1
+
+#include "parser.h"
+
+/* Advance of NUM lines. */
+# define LOCATION_LINES(Loc, Num) \
+ (Loc).last_column = 0; \
+ (Loc).last_line += Num;
+
+/* Restart: move the first cursor to the last position. */
+# define LOCATION_STEP(Loc) \
+ (Loc).first_column = (Loc).last_column; \
+ (Loc).first_line = (Loc).last_line;
+
+/* The lack of reference counting for filename is intentional */
+#define YY_USER_ACTION \
+ do { \
+ yylloc->last_column += yyleng; \
+ yylloc->filename = augl_get_info(yyscanner)->filename; \
+ yylloc->error = augl_get_info(yyscanner)->error; \
+ } while(0);
+
+#define YY_USER_INIT LOCATION_STEP(*yylloc)
+
+#define YY_EXTRA_TYPE struct state *
+
+int augl_init_lexer(struct state *state, yyscan_t * scanner);
+void augl_close_lexer(yyscan_t *scanner);
+struct info *augl_get_info(yyscan_t yyscanner);
+
+static void loc_update(YYLTYPE *yylloc, const char *s, int len) {
+ for (int i=0; i < len; i++) {
+ if (s[i] == '\n') {
+ LOCATION_LINES(*yylloc, 1);
+ }
+ }
+}
+
+static char *regexp_literal(const char *s, int len) {
+ char *u = unescape(s, len, RX_ESCAPES);
+
+ if (u == NULL)
+ return NULL;
+
+ size_t u_len = strlen(u);
+ regexp_c_locale(&u, &u_len);
+
+ return u;
+}
+
+#line 600 "lexer.c"
+
+#define INITIAL 0
+#define COMMENT 1
+
+#ifndef YY_NO_UNISTD_H
+/* Special case for "unistd.h", since it is non-ANSI. We include it way
+ * down here because we want the user's section 1 to have been scanned first.
+ * The user has a chance to override it with an option.
+ */
+#include
+#endif
+
+#ifndef YY_EXTRA_TYPE
+#define YY_EXTRA_TYPE void *
+#endif
+
+/* Holds the entire state of the reentrant scanner. */
+struct yyguts_t
+ {
+
+ /* User-defined. Not touched by flex. */
+ YY_EXTRA_TYPE yyextra_r;
+
+ /* The rest are the same as the globals declared in the non-reentrant scanner. */
+ FILE *yyin_r, *yyout_r;
+ size_t yy_buffer_stack_top; /**< index of top of stack. */
+ size_t yy_buffer_stack_max; /**< capacity of stack. */
+ YY_BUFFER_STATE * yy_buffer_stack; /**< Stack as an array. */
+ char yy_hold_char;
+ int yy_n_chars;
+ yy_size_t yyleng_r;
+ char *yy_c_buf_p;
+ int yy_init;
+ int yy_start;
+ int yy_did_buffer_switch_on_eof;
+ int yy_start_stack_ptr;
+ int yy_start_stack_depth;
+ int *yy_start_stack;
+ yy_state_type yy_last_accepting_state;
+ char* yy_last_accepting_cpos;
+
+ int yylineno_r;
+ int yy_flex_debug_r;
+
+ char *yytext_r;
+ int yy_more_flag;
+ int yy_more_len;
+
+ YYSTYPE * yylval_r;
+
+ YYLTYPE * yylloc_r;
+
+ }; /* end struct yyguts_t */
+
+static int yy_init_globals (yyscan_t yyscanner );
+
+ /* This must go here because YYSTYPE and YYLTYPE are included
+ * from bison output in section 1.*/
+ # define yylval yyg->yylval_r
+
+ # define yylloc yyg->yylloc_r
+
+int augl_lex_init (yyscan_t* scanner);
+
+int augl_lex_init_extra (YY_EXTRA_TYPE user_defined,yyscan_t* scanner);
+
+/* Accessor methods to globals.
+ These are made visible to non-reentrant scanners for convenience. */
+
+int augl_lex_destroy (yyscan_t yyscanner );
+
+int augl_get_debug (yyscan_t yyscanner );
+
+void augl_set_debug (int debug_flag ,yyscan_t yyscanner );
+
+YY_EXTRA_TYPE augl_get_extra (yyscan_t yyscanner );
+
+void augl_set_extra (YY_EXTRA_TYPE user_defined ,yyscan_t yyscanner );
+
+FILE *augl_get_in (yyscan_t yyscanner );
+
+void augl_set_in (FILE * _in_str ,yyscan_t yyscanner );
+
+FILE *augl_get_out (yyscan_t yyscanner );
+
+void augl_set_out (FILE * _out_str ,yyscan_t yyscanner );
+
+yy_size_t augl_get_leng (yyscan_t yyscanner );
+
+char *augl_get_text (yyscan_t yyscanner );
+
+int augl_get_lineno (yyscan_t yyscanner );
+
+void augl_set_lineno (int _line_number ,yyscan_t yyscanner );
+
+int augl_get_column (yyscan_t yyscanner );
+
+void augl_set_column (int _column_no ,yyscan_t yyscanner );
+
+YYSTYPE * augl_get_lval (yyscan_t yyscanner );
+
+void augl_set_lval (YYSTYPE * yylval_param ,yyscan_t yyscanner );
+
+ YYLTYPE *augl_get_lloc (yyscan_t yyscanner );
+
+ void augl_set_lloc (YYLTYPE * yylloc_param ,yyscan_t yyscanner );
+
+/* Macros after this point can all be overridden by user definitions in
+ * section 1.
+ */
+
+#ifndef YY_SKIP_YYWRAP
+#ifdef __cplusplus
+extern "C" int augl_wrap (yyscan_t yyscanner );
+#else
+extern int augl_wrap (yyscan_t yyscanner );
+#endif
+#endif
+
+#ifndef YY_NO_UNPUT
+
+#endif
+
+#ifndef yytext_ptr
+static void yy_flex_strncpy (char *,yyconst char *,int ,yyscan_t yyscanner);
+#endif
+
+#ifdef YY_NEED_STRLEN
+static int yy_flex_strlen (yyconst char * ,yyscan_t yyscanner);
+#endif
+
+#ifndef YY_NO_INPUT
+
+#ifdef __cplusplus
+static int yyinput (yyscan_t yyscanner );
+#else
+static int input (yyscan_t yyscanner );
+#endif
+
+#endif
+
+/* Amount of stuff to slurp up with each read. */
+#ifndef YY_READ_BUF_SIZE
+#ifdef __ia64__
+/* On IA-64, the buffer size is 16k, not 8k */
+#define YY_READ_BUF_SIZE 16384
+#else
+#define YY_READ_BUF_SIZE 8192
+#endif /* __ia64__ */
+#endif
+
+/* Copy whatever the last rule matched to the standard output. */
+#ifndef ECHO
+/* This used to be an fputs(), but since the string might contain NUL's,
+ * we now use fwrite().
+ */
+#define ECHO do { if (fwrite( yytext, yyleng, 1, yyout )) {} } while (0)
+#endif
+
+/* Gets input and stuffs it into "buf". number of characters read, or YY_NULL,
+ * is returned in "result".
+ */
+#ifndef YY_INPUT
+#define YY_INPUT(buf,result,max_size) \
+ if ( YY_CURRENT_BUFFER_LVALUE->yy_is_interactive ) \
+ { \
+ int c = '*'; \
+ size_t n; \
+ for ( n = 0; n < max_size && \
+ (c = getc( yyin )) != EOF && c != '\n'; ++n ) \
+ buf[n] = (char) c; \
+ if ( c == '\n' ) \
+ buf[n++] = (char) c; \
+ if ( c == EOF && ferror( yyin ) ) \
+ YY_FATAL_ERROR( "input in flex scanner failed" ); \
+ result = n; \
+ } \
+ else \
+ { \
+ errno=0; \
+ while ( (result = fread(buf, 1, max_size, yyin))==0 && ferror(yyin)) \
+ { \
+ if( errno != EINTR) \
+ { \
+ YY_FATAL_ERROR( "input in flex scanner failed" ); \
+ break; \
+ } \
+ errno=0; \
+ clearerr(yyin); \
+ } \
+ }\
+\
+
+#endif
+
+/* No semi-colon after return; correct usage is to write "yyterminate();" -
+ * we don't want an extra ';' after the "return" because that will cause
+ * some compilers to complain about unreachable statements.
+ */
+#ifndef yyterminate
+#define yyterminate() return YY_NULL
+#endif
+
+/* Number of entries by which start-condition stack grows. */
+#ifndef YY_START_STACK_INCR
+#define YY_START_STACK_INCR 25
+#endif
+
+/* Report a fatal error. */
+#ifndef YY_FATAL_ERROR
+#define YY_FATAL_ERROR(msg) yy_fatal_error( msg , yyscanner)
+#endif
+
+/* end tables serialization structures and prototypes */
+
+/* Default declaration of generated scanner - a define so the user can
+ * easily add parameters.
+ */
+#ifndef YY_DECL
+#define YY_DECL_IS_OURS 1
+
+extern int augl_lex \
+ (YYSTYPE * yylval_param,YYLTYPE * yylloc_param ,yyscan_t yyscanner);
+
+#define YY_DECL int augl_lex \
+ (YYSTYPE * yylval_param, YYLTYPE * yylloc_param , yyscan_t yyscanner)
+#endif /* !YY_DECL */
+
+/* Code executed at the beginning of each rule, after yytext and yyleng
+ * have been set up.
+ */
+#ifndef YY_USER_ACTION
+#define YY_USER_ACTION
+#endif
+
+/* Code executed at the end of each rule. */
+#ifndef YY_BREAK
+#define YY_BREAK /*LINTED*/break;
+#endif
+
+#define YY_RULE_SETUP \
+ YY_USER_ACTION
+
+/** The main scanner function which does all the work.
+ */
+YY_DECL
+{
+ yy_state_type yy_current_state;
+ char *yy_cp, *yy_bp;
+ int yy_act;
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+
+ yylval = yylval_param;
+
+ yylloc = yylloc_param;
+
+ if ( !yyg->yy_init )
+ {
+ yyg->yy_init = 1;
+
+#ifdef YY_USER_INIT
+ YY_USER_INIT;
+#endif
+
+ if ( ! yyg->yy_start )
+ yyg->yy_start = 1; /* first start state */
+
+ if ( ! yyin )
+ yyin = stdin;
+
+ if ( ! yyout )
+ yyout = stdout;
+
+ if ( ! YY_CURRENT_BUFFER ) {
+ augl_ensure_buffer_stack (yyscanner);
+ YY_CURRENT_BUFFER_LVALUE =
+ augl__create_buffer(yyin,YY_BUF_SIZE ,yyscanner);
+ }
+
+ augl__load_buffer_state(yyscanner );
+ }
+
+ {
+#line 81 "lexer.l"
+
+#line 886 "lexer.c"
+
+ while ( /*CONSTCOND*/1 ) /* loops until end-of-file is reached */
+ {
+ yy_cp = yyg->yy_c_buf_p;
+
+ /* Support of yytext. */
+ *yy_cp = yyg->yy_hold_char;
+
+ /* yy_bp points to the position in yy_ch_buf of the start of
+ * the current run.
+ */
+ yy_bp = yy_cp;
+
+ yy_current_state = yyg->yy_start;
+yy_match:
+ do
+ {
+ YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)] ;
+ if ( yy_accept[yy_current_state] )
+ {
+ yyg->yy_last_accepting_state = yy_current_state;
+ yyg->yy_last_accepting_cpos = yy_cp;
+ }
+ while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
+ {
+ yy_current_state = (int) yy_def[yy_current_state];
+ if ( yy_current_state >= 95 )
+ yy_c = yy_meta[(unsigned int) yy_c];
+ }
+ yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
+ ++yy_cp;
+ }
+ while ( yy_current_state != 94 );
+ yy_cp = yyg->yy_last_accepting_cpos;
+ yy_current_state = yyg->yy_last_accepting_state;
+
+yy_find_action:
+ yy_act = yy_accept[yy_current_state];
+
+ YY_DO_BEFORE_ACTION;
+
+ if ( yy_act != YY_END_OF_BUFFER && yy_rule_can_match_eol[yy_act] )
+ {
+ yy_size_t yyl;
+ for ( yyl = 0; yyl < yyleng; ++yyl )
+ if ( yytext[yyl] == '\n' )
+
+ do{ yylineno++;
+ yycolumn=0;
+ }while(0)
+;
+ }
+
+do_action: /* This label is used only to access EOF actions. */
+
+ switch ( yy_act )
+ { /* beginning of action switch */
+ case 0: /* must back up */
+ /* undo the effects of YY_DO_BEFORE_ACTION */
+ *yy_cp = yyg->yy_hold_char;
+ yy_cp = yyg->yy_last_accepting_cpos;
+ yy_current_state = yyg->yy_last_accepting_state;
+ goto yy_find_action;
+
+case 1:
+YY_RULE_SETUP
+#line 84 "lexer.l"
+LOCATION_STEP(*yylloc);
+ YY_BREAK
+case 2:
+/* rule 2 can match eol */
+YY_RULE_SETUP
+#line 85 "lexer.l"
+LOCATION_LINES(*yylloc, yyleng); LOCATION_STEP(*yylloc);
+ YY_BREAK
+case 3:
+/* rule 3 can match eol */
+YY_RULE_SETUP
+#line 86 "lexer.l"
+LOCATION_LINES(*yylloc, yyleng/2); LOCATION_STEP(*yylloc);
+ YY_BREAK
+
+
+
+case 4:
+/* rule 4 can match eol */
+YY_RULE_SETUP
+#line 91 "lexer.l"
+{
+ loc_update(yylloc, yytext, yyleng);
+ yylval->string = unescape(yytext+1, yyleng-2, STR_ESCAPES);
+ return DQUOTED;
+ }
+ YY_BREAK
+case 5:
+/* rule 5 can match eol */
+YY_RULE_SETUP
+#line 97 "lexer.l"
+{
+ loc_update(yylloc, yytext, yyleng);
+ yylval->regexp.nocase = 1;
+ yylval->regexp.pattern = regexp_literal(yytext+1, yyleng-3);
+ return REGEXP;
+ }
+ YY_BREAK
+case 6:
+/* rule 6 can match eol */
+YY_RULE_SETUP
+#line 104 "lexer.l"
+{
+ loc_update(yylloc, yytext, yyleng);
+ yylval->regexp.nocase = 0;
+ yylval->regexp.pattern = regexp_literal(yytext+1, yyleng-2);
+ return REGEXP;
+ }
+ YY_BREAK
+case 7:
+YY_RULE_SETUP
+#line 111 "lexer.l"
+return yytext[0];
+ YY_BREAK
+case 8:
+YY_RULE_SETUP
+#line 113 "lexer.l"
+return KW_MODULE;
+ YY_BREAK
+case 9:
+/* rule 9 can match eol */
+*yy_cp = yyg->yy_hold_char; /* undo effects of setting up yytext */
+YY_LINENO_REWIND_TO(yy_cp - 1);
+yyg->yy_c_buf_p = yy_cp -= 1;
+YY_DO_BEFORE_ACTION; /* set up yytext again */
+YY_RULE_SETUP
+#line 115 "lexer.l"
+return KW_LET_REC;
+ YY_BREAK
+case 10:
+YY_RULE_SETUP
+#line 117 "lexer.l"
+return KW_LET;
+ YY_BREAK
+case 11:
+YY_RULE_SETUP
+#line 118 "lexer.l"
+return KW_STRING;
+ YY_BREAK
+case 12:
+YY_RULE_SETUP
+#line 119 "lexer.l"
+return KW_REGEXP;
+ YY_BREAK
+case 13:
+YY_RULE_SETUP
+#line 120 "lexer.l"
+return KW_LENS;
+ YY_BREAK
+case 14:
+YY_RULE_SETUP
+#line 121 "lexer.l"
+return KW_IN;
+ YY_BREAK
+case 15:
+YY_RULE_SETUP
+#line 122 "lexer.l"
+return KW_AUTOLOAD;
+ YY_BREAK
+/* tests */
+case 16:
+YY_RULE_SETUP
+#line 125 "lexer.l"
+return KW_TEST;
+ YY_BREAK
+case 17:
+YY_RULE_SETUP
+#line 126 "lexer.l"
+return KW_GET;
+ YY_BREAK
+case 18:
+YY_RULE_SETUP
+#line 127 "lexer.l"
+return KW_PUT;
+ YY_BREAK
+case 19:
+YY_RULE_SETUP
+#line 128 "lexer.l"
+return KW_AFTER;
+ YY_BREAK
+case 20:
+YY_RULE_SETUP
+#line 130 "lexer.l"
+return ARROW;
+ YY_BREAK
+case 21:
+YY_RULE_SETUP
+#line 132 "lexer.l"
+{
+ yylval->string = strndup(yytext, yyleng);
+ return QIDENT;
+ }
+ YY_BREAK
+case 22:
+YY_RULE_SETUP
+#line 136 "lexer.l"
+{
+ yylval->string = strndup(yytext, yyleng);
+ return LIDENT;
+ }
+ YY_BREAK
+case 23:
+YY_RULE_SETUP
+#line 140 "lexer.l"
+{
+ yylval->string = strndup(yytext, yyleng);
+ return UIDENT;
+ }
+ YY_BREAK
+case 24:
+YY_RULE_SETUP
+#line 144 "lexer.l"
+{
+ augl_get_extra(yyscanner)->comment_depth = 1;
+ BEGIN(COMMENT);
+ }
+ YY_BREAK
+case 25:
+YY_RULE_SETUP
+#line 148 "lexer.l"
+{
+ report_error(augl_get_info(yyscanner)->error, AUG_ESYNTAX,
+ "%s:%d:%d: Unexpected character %c",
+ augl_get_info(yyscanner)->filename->str,
+ yylineno, yylloc->first_column, yytext[0]);
+ }
+ YY_BREAK
+case YY_STATE_EOF(INITIAL):
+#line 155 "lexer.l"
+{
+ augl_close_lexer(yyscanner);
+ yyterminate();
+ }
+ YY_BREAK
+
+
+
+case 26:
+YY_RULE_SETUP
+#line 164 "lexer.l"
+{
+ augl_get_extra(yyscanner)->comment_depth += 1;
+ }
+ YY_BREAK
+case 27:
+YY_RULE_SETUP
+#line 167 "lexer.l"
+{
+ augl_get_extra(yyscanner)->comment_depth -= 1;
+ if (augl_get_extra(yyscanner)->comment_depth == 0)
+ BEGIN(INITIAL);
+ }
+ YY_BREAK
+case 28:
+YY_RULE_SETUP
+#line 172 "lexer.l"
+/* Skip */;
+ YY_BREAK
+case YY_STATE_EOF(COMMENT):
+#line 173 "lexer.l"
+{
+ report_error(augl_get_info(yyscanner)->error, AUG_ESYNTAX,
+ "%s:%d:%d: Missing *)",
+ augl_get_info(yyscanner)->filename->str,
+ yylineno, yylloc->first_column);
+ augl_close_lexer(yyscanner);
+ yyterminate();
+ }
+ YY_BREAK
+
+case 29:
+YY_RULE_SETUP
+#line 182 "lexer.l"
+YY_FATAL_ERROR( "flex scanner jammed" );
+ YY_BREAK
+#line 1169 "lexer.c"
+
+ case YY_END_OF_BUFFER:
+ {
+ /* Amount of text matched not including the EOB char. */
+ int yy_amount_of_matched_text = (int) (yy_cp - yyg->yytext_ptr) - 1;
+
+ /* Undo the effects of YY_DO_BEFORE_ACTION. */
+ *yy_cp = yyg->yy_hold_char;
+ YY_RESTORE_YY_MORE_OFFSET
+
+ if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_NEW )
+ {
+ /* We're scanning a new file or input source. It's
+ * possible that this happened because the user
+ * just pointed yyin at a new source and called
+ * augl_lex(). If so, then we have to assure
+ * consistency between YY_CURRENT_BUFFER and our
+ * globals. Here is the right place to do so, because
+ * this is the first action (other than possibly a
+ * back-up) that will match for the new input source.
+ */
+ yyg->yy_n_chars = YY_CURRENT_BUFFER_LVALUE->yy_n_chars;
+ YY_CURRENT_BUFFER_LVALUE->yy_input_file = yyin;
+ YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = YY_BUFFER_NORMAL;
+ }
+
+ /* Note that here we test for yy_c_buf_p "<=" to the position
+ * of the first EOB in the buffer, since yy_c_buf_p will
+ * already have been incremented past the NUL character
+ * (since all states make transitions on EOB to the
+ * end-of-buffer state). Contrast this with the test
+ * in input().
+ */
+ if ( yyg->yy_c_buf_p <= &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars] )
+ { /* This was really a NUL. */
+ yy_state_type yy_next_state;
+
+ yyg->yy_c_buf_p = yyg->yytext_ptr + yy_amount_of_matched_text;
+
+ yy_current_state = yy_get_previous_state( yyscanner );
+
+ /* Okay, we're now positioned to make the NUL
+ * transition. We couldn't have
+ * yy_get_previous_state() go ahead and do it
+ * for us because it doesn't know how to deal
+ * with the possibility of jamming (and we don't
+ * want to build jamming into it because then it
+ * will run more slowly).
+ */
+
+ yy_next_state = yy_try_NUL_trans( yy_current_state , yyscanner);
+
+ yy_bp = yyg->yytext_ptr + YY_MORE_ADJ;
+
+ if ( yy_next_state )
+ {
+ /* Consume the NUL. */
+ yy_cp = ++yyg->yy_c_buf_p;
+ yy_current_state = yy_next_state;
+ goto yy_match;
+ }
+
+ else
+ {
+ yy_cp = yyg->yy_last_accepting_cpos;
+ yy_current_state = yyg->yy_last_accepting_state;
+ goto yy_find_action;
+ }
+ }
+
+ else switch ( yy_get_next_buffer( yyscanner ) )
+ {
+ case EOB_ACT_END_OF_FILE:
+ {
+ yyg->yy_did_buffer_switch_on_eof = 0;
+
+ if ( augl_wrap(yyscanner ) )
+ {
+ /* Note: because we've taken care in
+ * yy_get_next_buffer() to have set up
+ * yytext, we can now set up
+ * yy_c_buf_p so that if some total
+ * hoser (like flex itself) wants to
+ * call the scanner after we return the
+ * YY_NULL, it'll still work - another
+ * YY_NULL will get returned.
+ */
+ yyg->yy_c_buf_p = yyg->yytext_ptr + YY_MORE_ADJ;
+
+ yy_act = YY_STATE_EOF(YY_START);
+ goto do_action;
+ }
+
+ else
+ {
+ if ( ! yyg->yy_did_buffer_switch_on_eof )
+ YY_NEW_FILE;
+ }
+ break;
+ }
+
+ case EOB_ACT_CONTINUE_SCAN:
+ yyg->yy_c_buf_p =
+ yyg->yytext_ptr + yy_amount_of_matched_text;
+
+ yy_current_state = yy_get_previous_state( yyscanner );
+
+ yy_cp = yyg->yy_c_buf_p;
+ yy_bp = yyg->yytext_ptr + YY_MORE_ADJ;
+ goto yy_match;
+
+ case EOB_ACT_LAST_MATCH:
+ yyg->yy_c_buf_p =
+ &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars];
+
+ yy_current_state = yy_get_previous_state( yyscanner );
+
+ yy_cp = yyg->yy_c_buf_p;
+ yy_bp = yyg->yytext_ptr + YY_MORE_ADJ;
+ goto yy_find_action;
+ }
+ break;
+ }
+
+ default:
+ YY_FATAL_ERROR(
+ "fatal flex scanner internal error--no action found" );
+ } /* end of action switch */
+ } /* end of scanning one token */
+ } /* end of user's declarations */
+} /* end of augl_lex */
+
+/* yy_get_next_buffer - try to read in a new buffer
+ *
+ * Returns a code representing an action:
+ * EOB_ACT_LAST_MATCH -
+ * EOB_ACT_CONTINUE_SCAN - continue scanning from current position
+ * EOB_ACT_END_OF_FILE - end of file
+ */
+static int yy_get_next_buffer (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ char *dest = YY_CURRENT_BUFFER_LVALUE->yy_ch_buf;
+ char *source = yyg->yytext_ptr;
+ yy_size_t number_to_move, i;
+ int ret_val;
+
+ if ( yyg->yy_c_buf_p > &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars + 1] )
+ YY_FATAL_ERROR(
+ "fatal flex scanner internal error--end of buffer missed" );
+
+ if ( YY_CURRENT_BUFFER_LVALUE->yy_fill_buffer == 0 )
+ { /* Don't try to fill the buffer, so this is an EOF. */
+ if ( yyg->yy_c_buf_p - yyg->yytext_ptr - YY_MORE_ADJ == 1 )
+ {
+ /* We matched a single character, the EOB, so
+ * treat this as a final EOF.
+ */
+ return EOB_ACT_END_OF_FILE;
+ }
+
+ else
+ {
+ /* We matched some text prior to the EOB, first
+ * process it.
+ */
+ return EOB_ACT_LAST_MATCH;
+ }
+ }
+
+ /* Try to read more data. */
+
+ /* First move last chars to start of buffer. */
+ number_to_move = (yy_size_t) (yyg->yy_c_buf_p - yyg->yytext_ptr) - 1;
+
+ for ( i = 0; i < number_to_move; ++i )
+ *(dest++) = *(source++);
+
+ if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_EOF_PENDING )
+ /* don't do the read, it's not guaranteed to return an EOF,
+ * just force an EOF
+ */
+ YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars = 0;
+
+ else
+ {
+ yy_size_t num_to_read =
+ YY_CURRENT_BUFFER_LVALUE->yy_buf_size - number_to_move - 1;
+
+ while ( num_to_read <= 0 )
+ { /* Not enough room in the buffer - grow it. */
+
+ /* just a shorter name for the current buffer */
+ YY_BUFFER_STATE b = YY_CURRENT_BUFFER_LVALUE;
+
+ int yy_c_buf_p_offset =
+ (int) (yyg->yy_c_buf_p - b->yy_ch_buf);
+
+ if ( b->yy_is_our_buffer )
+ {
+ yy_size_t new_size = b->yy_buf_size * 2;
+
+ if ( new_size <= 0 )
+ b->yy_buf_size += b->yy_buf_size / 8;
+ else
+ b->yy_buf_size *= 2;
+
+ b->yy_ch_buf = (char *)
+ /* Include room in for 2 EOB chars. */
+ augl_realloc((void *) b->yy_ch_buf,b->yy_buf_size + 2 ,yyscanner );
+ }
+ else
+ /* Can't grow it, we don't own it. */
+ b->yy_ch_buf = 0;
+
+ if ( ! b->yy_ch_buf )
+ YY_FATAL_ERROR(
+ "fatal error - scanner input buffer overflow" );
+
+ yyg->yy_c_buf_p = &b->yy_ch_buf[yy_c_buf_p_offset];
+
+ num_to_read = YY_CURRENT_BUFFER_LVALUE->yy_buf_size -
+ number_to_move - 1;
+
+ }
+
+ if ( num_to_read > YY_READ_BUF_SIZE )
+ num_to_read = YY_READ_BUF_SIZE;
+
+ /* Read in more data. */
+ YY_INPUT( (&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move]),
+ yyg->yy_n_chars, num_to_read );
+
+ YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars;
+ }
+
+ if ( yyg->yy_n_chars == 0 )
+ {
+ if ( number_to_move == YY_MORE_ADJ )
+ {
+ ret_val = EOB_ACT_END_OF_FILE;
+ augl_restart(yyin ,yyscanner);
+ }
+
+ else
+ {
+ ret_val = EOB_ACT_LAST_MATCH;
+ YY_CURRENT_BUFFER_LVALUE->yy_buffer_status =
+ YY_BUFFER_EOF_PENDING;
+ }
+ }
+
+ else
+ ret_val = EOB_ACT_CONTINUE_SCAN;
+
+ if ((int) (yyg->yy_n_chars + number_to_move) > YY_CURRENT_BUFFER_LVALUE->yy_buf_size) {
+ /* Extend the array by 50%, plus the number we really need. */
+ int new_size = yyg->yy_n_chars + number_to_move + (yyg->yy_n_chars >> 1);
+ YY_CURRENT_BUFFER_LVALUE->yy_ch_buf = (char *) augl_realloc((void *) YY_CURRENT_BUFFER_LVALUE->yy_ch_buf,new_size ,yyscanner );
+ if ( ! YY_CURRENT_BUFFER_LVALUE->yy_ch_buf )
+ YY_FATAL_ERROR( "out of dynamic memory in yy_get_next_buffer()" );
+ }
+
+ yyg->yy_n_chars += number_to_move;
+ YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars] = YY_END_OF_BUFFER_CHAR;
+ YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars + 1] = YY_END_OF_BUFFER_CHAR;
+
+ yyg->yytext_ptr = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[0];
+
+ return ret_val;
+}
+
+/* yy_get_previous_state - get the state just before the EOB char was reached */
+
+ static yy_state_type yy_get_previous_state (yyscan_t yyscanner)
+{
+ yy_state_type yy_current_state;
+ char *yy_cp;
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+
+ yy_current_state = yyg->yy_start;
+
+ for ( yy_cp = yyg->yytext_ptr + YY_MORE_ADJ; yy_cp < yyg->yy_c_buf_p; ++yy_cp )
+ {
+ YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1);
+ if ( yy_accept[yy_current_state] )
+ {
+ yyg->yy_last_accepting_state = yy_current_state;
+ yyg->yy_last_accepting_cpos = yy_cp;
+ }
+ while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
+ {
+ yy_current_state = (int) yy_def[yy_current_state];
+ if ( yy_current_state >= 95 )
+ yy_c = yy_meta[(unsigned int) yy_c];
+ }
+ yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
+ }
+
+ return yy_current_state;
+}
+
+/* yy_try_NUL_trans - try to make a transition on the NUL character
+ *
+ * synopsis
+ * next_state = yy_try_NUL_trans( current_state );
+ */
+ static yy_state_type yy_try_NUL_trans (yy_state_type yy_current_state , yyscan_t yyscanner)
+{
+ int yy_is_jam;
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; /* This var may be unused depending upon options. */
+ char *yy_cp = yyg->yy_c_buf_p;
+
+ YY_CHAR yy_c = 1;
+ if ( yy_accept[yy_current_state] )
+ {
+ yyg->yy_last_accepting_state = yy_current_state;
+ yyg->yy_last_accepting_cpos = yy_cp;
+ }
+ while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
+ {
+ yy_current_state = (int) yy_def[yy_current_state];
+ if ( yy_current_state >= 95 )
+ yy_c = yy_meta[(unsigned int) yy_c];
+ }
+ yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
+ yy_is_jam = (yy_current_state == 94);
+
+ (void)yyg;
+ return yy_is_jam ? 0 : yy_current_state;
+}
+
+#ifndef YY_NO_UNPUT
+
+#endif
+
+#ifndef YY_NO_INPUT
+#ifdef __cplusplus
+ static int yyinput (yyscan_t yyscanner)
+#else
+ static int input (yyscan_t yyscanner)
+#endif
+
+{
+ int c;
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+
+ *yyg->yy_c_buf_p = yyg->yy_hold_char;
+
+ if ( *yyg->yy_c_buf_p == YY_END_OF_BUFFER_CHAR )
+ {
+ /* yy_c_buf_p now points to the character we want to return.
+ * If this occurs *before* the EOB characters, then it's a
+ * valid NUL; if not, then we've hit the end of the buffer.
+ */
+ if ( yyg->yy_c_buf_p < &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars] )
+ /* This was really a NUL. */
+ *yyg->yy_c_buf_p = '\0';
+
+ else
+ { /* need more input */
+ yy_size_t offset = yyg->yy_c_buf_p - yyg->yytext_ptr;
+ ++yyg->yy_c_buf_p;
+
+ switch ( yy_get_next_buffer( yyscanner ) )
+ {
+ case EOB_ACT_LAST_MATCH:
+ /* This happens because yy_g_n_b()
+ * sees that we've accumulated a
+ * token and flags that we need to
+ * try matching the token before
+ * proceeding. But for input(),
+ * there's no matching to consider.
+ * So convert the EOB_ACT_LAST_MATCH
+ * to EOB_ACT_END_OF_FILE.
+ */
+
+ /* Reset buffer status. */
+ augl_restart(yyin ,yyscanner);
+
+ /*FALLTHROUGH*/
+
+ case EOB_ACT_END_OF_FILE:
+ {
+ if ( augl_wrap(yyscanner ) )
+ return EOF;
+
+ if ( ! yyg->yy_did_buffer_switch_on_eof )
+ YY_NEW_FILE;
+#ifdef __cplusplus
+ return yyinput(yyscanner);
+#else
+ return input(yyscanner);
+#endif
+ }
+
+ case EOB_ACT_CONTINUE_SCAN:
+ yyg->yy_c_buf_p = yyg->yytext_ptr + offset;
+ break;
+ }
+ }
+ }
+
+ c = *(unsigned char *) yyg->yy_c_buf_p; /* cast for 8-bit char's */
+ *yyg->yy_c_buf_p = '\0'; /* preserve yytext */
+ yyg->yy_hold_char = *++yyg->yy_c_buf_p;
+
+ if ( c == '\n' )
+
+ do{ yylineno++;
+ yycolumn=0;
+ }while(0)
+;
+
+ return c;
+}
+#endif /* ifndef YY_NO_INPUT */
+
+/** Immediately switch to a different input stream.
+ * @param input_file A readable stream.
+ * @param yyscanner The scanner object.
+ * @note This function does not reset the start condition to @c INITIAL .
+ */
+ void augl_restart (FILE * input_file , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+
+ if ( ! YY_CURRENT_BUFFER ){
+ augl_ensure_buffer_stack (yyscanner);
+ YY_CURRENT_BUFFER_LVALUE =
+ augl__create_buffer(yyin,YY_BUF_SIZE ,yyscanner);
+ }
+
+ augl__init_buffer(YY_CURRENT_BUFFER,input_file ,yyscanner);
+ augl__load_buffer_state(yyscanner );
+}
+
+/** Switch to a different input buffer.
+ * @param new_buffer The new input buffer.
+ * @param yyscanner The scanner object.
+ */
+ void augl__switch_to_buffer (YY_BUFFER_STATE new_buffer , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+
+ /* TODO. We should be able to replace this entire function body
+ * with
+ * augl_pop_buffer_state();
+ * augl_push_buffer_state(new_buffer);
+ */
+ augl_ensure_buffer_stack (yyscanner);
+ if ( YY_CURRENT_BUFFER == new_buffer )
+ return;
+
+ if ( YY_CURRENT_BUFFER )
+ {
+ /* Flush out information for old buffer. */
+ *yyg->yy_c_buf_p = yyg->yy_hold_char;
+ YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = yyg->yy_c_buf_p;
+ YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars;
+ }
+
+ YY_CURRENT_BUFFER_LVALUE = new_buffer;
+ augl__load_buffer_state(yyscanner );
+
+ /* We don't actually know whether we did this switch during
+ * EOF (augl_wrap()) processing, but the only time this flag
+ * is looked at is after augl_wrap() is called, so it's safe
+ * to go ahead and always set it.
+ */
+ yyg->yy_did_buffer_switch_on_eof = 1;
+}
+
+static void augl__load_buffer_state (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ yyg->yy_n_chars = YY_CURRENT_BUFFER_LVALUE->yy_n_chars;
+ yyg->yytext_ptr = yyg->yy_c_buf_p = YY_CURRENT_BUFFER_LVALUE->yy_buf_pos;
+ yyin = YY_CURRENT_BUFFER_LVALUE->yy_input_file;
+ yyg->yy_hold_char = *yyg->yy_c_buf_p;
+}
+
+/** Allocate and initialize an input buffer state.
+ * @param file A readable stream.
+ * @param size The character buffer size in bytes. When in doubt, use @c YY_BUF_SIZE.
+ * @param yyscanner The scanner object.
+ * @return the allocated buffer state.
+ */
+ YY_BUFFER_STATE augl__create_buffer (FILE * file, int size , yyscan_t yyscanner)
+{
+ YY_BUFFER_STATE b;
+
+ b = (YY_BUFFER_STATE) augl_alloc(sizeof( struct yy_buffer_state ) ,yyscanner );
+ if ( ! b )
+ YY_FATAL_ERROR( "out of dynamic memory in augl__create_buffer()" );
+
+ b->yy_buf_size = (yy_size_t)size;
+
+ /* yy_ch_buf has to be 2 characters longer than the size given because
+ * we need to put in 2 end-of-buffer characters.
+ */
+ b->yy_ch_buf = (char *) augl_alloc(b->yy_buf_size + 2 ,yyscanner );
+ if ( ! b->yy_ch_buf )
+ YY_FATAL_ERROR( "out of dynamic memory in augl__create_buffer()" );
+
+ b->yy_is_our_buffer = 1;
+
+ augl__init_buffer(b,file ,yyscanner);
+
+ return b;
+}
+
+/** Destroy the buffer.
+ * @param b a buffer created with augl__create_buffer()
+ * @param yyscanner The scanner object.
+ */
+ void augl__delete_buffer (YY_BUFFER_STATE b , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+
+ if ( ! b )
+ return;
+
+ if ( b == YY_CURRENT_BUFFER ) /* Not sure if we should pop here. */
+ YY_CURRENT_BUFFER_LVALUE = (YY_BUFFER_STATE) 0;
+
+ if ( b->yy_is_our_buffer )
+ augl_free((void *) b->yy_ch_buf ,yyscanner );
+
+ augl_free((void *) b ,yyscanner );
+}
+
+/* Initializes or reinitializes a buffer.
+ * This function is sometimes called more than once on the same buffer,
+ * such as during a augl_restart() or at EOF.
+ */
+ static void augl__init_buffer (YY_BUFFER_STATE b, FILE * file , yyscan_t yyscanner)
+
+{
+ int oerrno = errno;
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+
+ augl__flush_buffer(b ,yyscanner);
+
+ b->yy_input_file = file;
+ b->yy_fill_buffer = 1;
+
+ /* If b is the current buffer, then augl__init_buffer was _probably_
+ * called from augl_restart() or through yy_get_next_buffer.
+ * In that case, we don't want to reset the lineno or column.
+ */
+ if (b != YY_CURRENT_BUFFER){
+ b->yy_bs_lineno = 1;
+ b->yy_bs_column = 0;
+ }
+
+ b->yy_is_interactive = 0;
+
+ errno = oerrno;
+}
+
+/** Discard all buffered characters. On the next scan, YY_INPUT will be called.
+ * @param b the buffer state to be flushed, usually @c YY_CURRENT_BUFFER.
+ * @param yyscanner The scanner object.
+ */
+ void augl__flush_buffer (YY_BUFFER_STATE b , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ if ( ! b )
+ return;
+
+ b->yy_n_chars = 0;
+
+ /* We always need two end-of-buffer characters. The first causes
+ * a transition to the end-of-buffer state. The second causes
+ * a jam in that state.
+ */
+ b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR;
+ b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR;
+
+ b->yy_buf_pos = &b->yy_ch_buf[0];
+
+ b->yy_at_bol = 1;
+ b->yy_buffer_status = YY_BUFFER_NEW;
+
+ if ( b == YY_CURRENT_BUFFER )
+ augl__load_buffer_state(yyscanner );
+}
+
+/** Pushes the new state onto the stack. The new state becomes
+ * the current state. This function will allocate the stack
+ * if necessary.
+ * @param new_buffer The new state.
+ * @param yyscanner The scanner object.
+ */
+void augl_push_buffer_state (YY_BUFFER_STATE new_buffer , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ if (new_buffer == NULL)
+ return;
+
+ augl_ensure_buffer_stack(yyscanner);
+
+ /* This block is copied from augl__switch_to_buffer. */
+ if ( YY_CURRENT_BUFFER )
+ {
+ /* Flush out information for old buffer. */
+ *yyg->yy_c_buf_p = yyg->yy_hold_char;
+ YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = yyg->yy_c_buf_p;
+ YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars;
+ }
+
+ /* Only push if top exists. Otherwise, replace top. */
+ if (YY_CURRENT_BUFFER)
+ yyg->yy_buffer_stack_top++;
+ YY_CURRENT_BUFFER_LVALUE = new_buffer;
+
+ /* copied from augl__switch_to_buffer. */
+ augl__load_buffer_state(yyscanner );
+ yyg->yy_did_buffer_switch_on_eof = 1;
+}
+
+/** Removes and deletes the top of the stack, if present.
+ * The next element becomes the new top.
+ * @param yyscanner The scanner object.
+ */
+void augl_pop_buffer_state (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ if (!YY_CURRENT_BUFFER)
+ return;
+
+ augl__delete_buffer(YY_CURRENT_BUFFER ,yyscanner);
+ YY_CURRENT_BUFFER_LVALUE = NULL;
+ if (yyg->yy_buffer_stack_top > 0)
+ --yyg->yy_buffer_stack_top;
+
+ if (YY_CURRENT_BUFFER) {
+ augl__load_buffer_state(yyscanner );
+ yyg->yy_did_buffer_switch_on_eof = 1;
+ }
+}
+
+/* Allocates the stack if it does not exist.
+ * Guarantees space for at least one push.
+ */
+static void augl_ensure_buffer_stack (yyscan_t yyscanner)
+{
+ yy_size_t num_to_alloc;
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+
+ if (!yyg->yy_buffer_stack) {
+
+ /* First allocation is just for 2 elements, since we don't know if this
+ * scanner will even need a stack. We use 2 instead of 1 to avoid an
+ * immediate realloc on the next call.
+ */
+ num_to_alloc = 1; /* After all that talk, this was set to 1 anyways... */
+ yyg->yy_buffer_stack = (struct yy_buffer_state**)augl_alloc
+ (num_to_alloc * sizeof(struct yy_buffer_state*)
+ , yyscanner);
+ if ( ! yyg->yy_buffer_stack )
+ YY_FATAL_ERROR( "out of dynamic memory in augl_ensure_buffer_stack()" );
+
+ memset(yyg->yy_buffer_stack, 0, num_to_alloc * sizeof(struct yy_buffer_state*));
+
+ yyg->yy_buffer_stack_max = num_to_alloc;
+ yyg->yy_buffer_stack_top = 0;
+ return;
+ }
+
+ if (yyg->yy_buffer_stack_top >= (yyg->yy_buffer_stack_max) - 1){
+
+ /* Increase the buffer to prepare for a possible push. */
+ yy_size_t grow_size = 8 /* arbitrary grow size */;
+
+ num_to_alloc = yyg->yy_buffer_stack_max + grow_size;
+ yyg->yy_buffer_stack = (struct yy_buffer_state**)augl_realloc
+ (yyg->yy_buffer_stack,
+ num_to_alloc * sizeof(struct yy_buffer_state*)
+ , yyscanner);
+ if ( ! yyg->yy_buffer_stack )
+ YY_FATAL_ERROR( "out of dynamic memory in augl_ensure_buffer_stack()" );
+
+ /* zero only the new slots.*/
+ memset(yyg->yy_buffer_stack + yyg->yy_buffer_stack_max, 0, grow_size * sizeof(struct yy_buffer_state*));
+ yyg->yy_buffer_stack_max = num_to_alloc;
+ }
+}
+
+/** Setup the input buffer state to scan directly from a user-specified character buffer.
+ * @param base the character buffer
+ * @param size the size in bytes of the character buffer
+ * @param yyscanner The scanner object.
+ * @return the newly allocated buffer state object.
+ */
+YY_BUFFER_STATE augl__scan_buffer (char * base, yy_size_t size , yyscan_t yyscanner)
+{
+ YY_BUFFER_STATE b;
+
+ if ( size < 2 ||
+ base[size-2] != YY_END_OF_BUFFER_CHAR ||
+ base[size-1] != YY_END_OF_BUFFER_CHAR )
+ /* They forgot to leave room for the EOB's. */
+ return 0;
+
+ b = (YY_BUFFER_STATE) augl_alloc(sizeof( struct yy_buffer_state ) ,yyscanner );
+ if ( ! b )
+ YY_FATAL_ERROR( "out of dynamic memory in augl__scan_buffer()" );
+
+ b->yy_buf_size = size - 2; /* "- 2" to take care of EOB's */
+ b->yy_buf_pos = b->yy_ch_buf = base;
+ b->yy_is_our_buffer = 0;
+ b->yy_input_file = 0;
+ b->yy_n_chars = b->yy_buf_size;
+ b->yy_is_interactive = 0;
+ b->yy_at_bol = 1;
+ b->yy_fill_buffer = 0;
+ b->yy_buffer_status = YY_BUFFER_NEW;
+
+ augl__switch_to_buffer(b ,yyscanner );
+
+ return b;
+}
+
+/** Setup the input buffer state to scan a string. The next call to augl_lex() will
+ * scan from a @e copy of @a str.
+ * @param yystr a NUL-terminated string to scan
+ * @param yyscanner The scanner object.
+ * @return the newly allocated buffer state object.
+ * @note If you want to scan bytes that may contain NUL values, then use
+ * augl__scan_bytes() instead.
+ */
+YY_BUFFER_STATE augl__scan_string (yyconst char * yystr , yyscan_t yyscanner)
+{
+
+ return augl__scan_bytes(yystr,strlen(yystr) ,yyscanner);
+}
+
+/** Setup the input buffer state to scan the given bytes. The next call to augl_lex() will
+ * scan from a @e copy of @a bytes.
+ * @param yybytes the byte buffer to scan
+ * @param _yybytes_len the number of bytes in the buffer pointed to by @a bytes.
+ * @param yyscanner The scanner object.
+ * @return the newly allocated buffer state object.
+ */
+YY_BUFFER_STATE augl__scan_bytes (yyconst char * yybytes, yy_size_t _yybytes_len , yyscan_t yyscanner)
+{
+ YY_BUFFER_STATE b;
+ char *buf;
+ yy_size_t n;
+ yy_size_t i;
+
+ /* Get memory for full buffer, including space for trailing EOB's. */
+ n = _yybytes_len + 2;
+ buf = (char *) augl_alloc(n ,yyscanner );
+ if ( ! buf )
+ YY_FATAL_ERROR( "out of dynamic memory in augl__scan_bytes()" );
+
+ for ( i = 0; i < _yybytes_len; ++i )
+ buf[i] = yybytes[i];
+
+ buf[_yybytes_len] = buf[_yybytes_len+1] = YY_END_OF_BUFFER_CHAR;
+
+ b = augl__scan_buffer(buf,n ,yyscanner);
+ if ( ! b )
+ YY_FATAL_ERROR( "bad buffer in augl__scan_bytes()" );
+
+ /* It's okay to grow etc. this buffer, and we should throw it
+ * away when we're done.
+ */
+ b->yy_is_our_buffer = 1;
+
+ return b;
+}
+
+#ifndef YY_EXIT_FAILURE
+#define YY_EXIT_FAILURE 2
+#endif
+
+static void yy_fatal_error (yyconst char* msg , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ (void)yyg;
+ (void) fprintf( stderr, "%s\n", msg );
+ exit( YY_EXIT_FAILURE );
+}
+
+/* Redefine yyless() so it works in section 3 code. */
+
+#undef yyless
+#define yyless(n) \
+ do \
+ { \
+ /* Undo effects of setting up yytext. */ \
+ int yyless_macro_arg = (n); \
+ YY_LESS_LINENO(yyless_macro_arg);\
+ yytext[yyleng] = yyg->yy_hold_char; \
+ yyg->yy_c_buf_p = yytext + yyless_macro_arg; \
+ yyg->yy_hold_char = *yyg->yy_c_buf_p; \
+ *yyg->yy_c_buf_p = '\0'; \
+ yyleng = yyless_macro_arg; \
+ } \
+ while ( 0 )
+
+/* Accessor methods (get/set functions) to struct members. */
+
+/** Get the user-defined data for this scanner.
+ * @param yyscanner The scanner object.
+ */
+YY_EXTRA_TYPE augl_get_extra (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ return yyextra;
+}
+
+/** Get the current line number.
+ * @param yyscanner The scanner object.
+ */
+int augl_get_lineno (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+
+ if (! YY_CURRENT_BUFFER)
+ return 0;
+
+ return yylineno;
+}
+
+/** Get the current column number.
+ * @param yyscanner The scanner object.
+ */
+int augl_get_column (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+
+ if (! YY_CURRENT_BUFFER)
+ return 0;
+
+ return yycolumn;
+}
+
+/** Get the input stream.
+ * @param yyscanner The scanner object.
+ */
+FILE *augl_get_in (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ return yyin;
+}
+
+/** Get the output stream.
+ * @param yyscanner The scanner object.
+ */
+FILE *augl_get_out (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ return yyout;
+}
+
+/** Get the length of the current token.
+ * @param yyscanner The scanner object.
+ */
+yy_size_t augl_get_leng (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ return yyleng;
+}
+
+/** Get the current token.
+ * @param yyscanner The scanner object.
+ */
+
+char *augl_get_text (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ return yytext;
+}
+
+/** Set the user-defined data. This data is never touched by the scanner.
+ * @param user_defined The data to be associated with this scanner.
+ * @param yyscanner The scanner object.
+ */
+void augl_set_extra (YY_EXTRA_TYPE user_defined , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ yyextra = user_defined ;
+}
+
+/** Set the current line number.
+ * @param _line_number line number
+ * @param yyscanner The scanner object.
+ */
+void augl_set_lineno (int _line_number , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+
+ /* lineno is only valid if an input buffer exists. */
+ if (! YY_CURRENT_BUFFER )
+ YY_FATAL_ERROR( "augl_set_lineno called with no buffer" );
+
+ yylineno = _line_number;
+}
+
+/** Set the current column.
+ * @param _column_no column number
+ * @param yyscanner The scanner object.
+ */
+void augl_set_column (int _column_no , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+
+ /* column is only valid if an input buffer exists. */
+ if (! YY_CURRENT_BUFFER )
+ YY_FATAL_ERROR( "augl_set_column called with no buffer" );
+
+ yycolumn = _column_no;
+}
+
+/** Set the input stream. This does not discard the current
+ * input buffer.
+ * @param _in_str A readable stream.
+ * @param yyscanner The scanner object.
+ * @see augl__switch_to_buffer
+ */
+void augl_set_in (FILE * _in_str , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ yyin = _in_str ;
+}
+
+void augl_set_out (FILE * _out_str , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ yyout = _out_str ;
+}
+
+int augl_get_debug (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ return yy_flex_debug;
+}
+
+void augl_set_debug (int _bdebug , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ yy_flex_debug = _bdebug ;
+}
+
+/* Accessor methods for yylval and yylloc */
+
+YYSTYPE * augl_get_lval (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ return yylval;
+}
+
+void augl_set_lval (YYSTYPE * yylval_param , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ yylval = yylval_param;
+}
+
+YYLTYPE *augl_get_lloc (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ return yylloc;
+}
+
+void augl_set_lloc (YYLTYPE * yylloc_param , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ yylloc = yylloc_param;
+}
+
+/* User-visible API */
+
+/* augl_lex_init is special because it creates the scanner itself, so it is
+ * the ONLY reentrant function that doesn't take the scanner as the last argument.
+ * That's why we explicitly handle the declaration, instead of using our macros.
+ */
+
+int augl_lex_init(yyscan_t* ptr_yy_globals)
+
+{
+ if (ptr_yy_globals == NULL){
+ errno = EINVAL;
+ return 1;
+ }
+
+ *ptr_yy_globals = (yyscan_t) augl_alloc ( sizeof( struct yyguts_t ), NULL );
+
+ if (*ptr_yy_globals == NULL){
+ errno = ENOMEM;
+ return 1;
+ }
+
+ /* By setting to 0xAA, we expose bugs in yy_init_globals. Leave at 0x00 for releases. */
+ memset(*ptr_yy_globals,0x00,sizeof(struct yyguts_t));
+
+ return yy_init_globals ( *ptr_yy_globals );
+}
+
+/* augl_lex_init_extra has the same functionality as augl_lex_init, but follows the
+ * convention of taking the scanner as the last argument. Note however, that
+ * this is a *pointer* to a scanner, as it will be allocated by this call (and
+ * is the reason, too, why this function also must handle its own declaration).
+ * The user defined value in the first argument will be available to augl_alloc in
+ * the yyextra field.
+ */
+
+int augl_lex_init_extra(YY_EXTRA_TYPE yy_user_defined,yyscan_t* ptr_yy_globals )
+
+{
+ struct yyguts_t dummy_yyguts;
+
+ augl_set_extra (yy_user_defined, &dummy_yyguts);
+
+ if (ptr_yy_globals == NULL){
+ errno = EINVAL;
+ return 1;
+ }
+
+ *ptr_yy_globals = (yyscan_t) augl_alloc ( sizeof( struct yyguts_t ), &dummy_yyguts );
+
+ if (*ptr_yy_globals == NULL){
+ errno = ENOMEM;
+ return 1;
+ }
+
+ /* By setting to 0xAA, we expose bugs in
+ yy_init_globals. Leave at 0x00 for releases. */
+ memset(*ptr_yy_globals,0x00,sizeof(struct yyguts_t));
+
+ augl_set_extra (yy_user_defined, *ptr_yy_globals);
+
+ return yy_init_globals ( *ptr_yy_globals );
+}
+
+static int yy_init_globals (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ /* Initialization is the same as for the non-reentrant scanner.
+ * This function is called from augl_lex_destroy(), so don't allocate here.
+ */
+
+ yyg->yy_buffer_stack = 0;
+ yyg->yy_buffer_stack_top = 0;
+ yyg->yy_buffer_stack_max = 0;
+ yyg->yy_c_buf_p = (char *) 0;
+ yyg->yy_init = 0;
+ yyg->yy_start = 0;
+
+ yyg->yy_start_stack_ptr = 0;
+ yyg->yy_start_stack_depth = 0;
+ yyg->yy_start_stack = NULL;
+
+/* Defined in main.c */
+#ifdef YY_STDINIT
+ yyin = stdin;
+ yyout = stdout;
+#else
+ yyin = (FILE *) 0;
+ yyout = (FILE *) 0;
+#endif
+
+ /* For future reference: Set errno on error, since we are called by
+ * augl_lex_init()
+ */
+ return 0;
+}
+
+/* augl_lex_destroy is for both reentrant and non-reentrant scanners. */
+int augl_lex_destroy (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+
+ /* Pop the buffer stack, destroying each element. */
+ while(YY_CURRENT_BUFFER){
+ augl__delete_buffer(YY_CURRENT_BUFFER ,yyscanner );
+ YY_CURRENT_BUFFER_LVALUE = NULL;
+ augl_pop_buffer_state(yyscanner);
+ }
+
+ /* Destroy the stack itself. */
+ augl_free(yyg->yy_buffer_stack ,yyscanner);
+ yyg->yy_buffer_stack = NULL;
+
+ /* Destroy the start condition stack. */
+ augl_free(yyg->yy_start_stack ,yyscanner );
+ yyg->yy_start_stack = NULL;
+
+ /* Reset the globals. This is important in a non-reentrant scanner so the next time
+ * augl_lex() is called, initialization will occur. */
+ yy_init_globals( yyscanner);
+
+ /* Destroy the main struct (reentrant only). */
+ augl_free ( yyscanner , yyscanner );
+ yyscanner = NULL;
+ return 0;
+}
+
+/*
+ * Internal utility routines.
+ */
+
+#ifndef yytext_ptr
+static void yy_flex_strncpy (char* s1, yyconst char * s2, int n , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ (void)yyg;
+
+ int i;
+ for ( i = 0; i < n; ++i )
+ s1[i] = s2[i];
+}
+#endif
+
+#ifdef YY_NEED_STRLEN
+static int yy_flex_strlen (yyconst char * s , yyscan_t yyscanner)
+{
+ int n;
+ for ( n = 0; s[n]; ++n )
+ ;
+
+ return n;
+}
+#endif
+
+void *augl_alloc (yy_size_t size , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ (void)yyg;
+ return (void *) malloc( size );
+}
+
+void *augl_realloc (void * ptr, yy_size_t size , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ (void)yyg;
+
+ /* The cast to (char *) in the following accommodates both
+ * implementations that use char* generic pointers, and those
+ * that use void* generic pointers. It works with the latter
+ * because both ANSI C and C++ allow castless assignment from
+ * any pointer type to void*, and deal with argument conversions
+ * as though doing an assignment.
+ */
+ return (void *) realloc( (char *) ptr, size );
+}
+
+void augl_free (void * ptr , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ (void)yyg;
+ free( (char *) ptr ); /* see augl_realloc() for (char *) cast */
+}
+
+#define YYTABLES_NAME "yytables"
+
+#line 182 "lexer.l"
+
+
+
+void augl_close_lexer(yyscan_t *scanner) {
+ FILE *fp = augl_get_in(scanner);
+
+ if (fp != NULL) {
+ fclose(fp);
+ augl_set_in(NULL, scanner);
+ }
+}
+
+int augl_init_lexer(struct state *state, yyscan_t *scanner) {
+ FILE *f;
+ struct string *name = state->info->filename;
+
+ f = fopen(name->str, "r");
+ if (f == NULL)
+ return -1;
+
+ if (augl_lex_init(scanner) != 0) {
+ fclose(f);
+ return -1;
+ }
+ augl_set_extra(state, *scanner);
+ augl_set_in(f, *scanner);
+ return 0;
+}
+
+struct info *augl_get_info(yyscan_t scanner) {
+ return augl_get_extra(scanner)->info;
+}
+
diff --git a/libraries/cmake/source/augeas/generated/linux/aarch64/code/parser.c b/libraries/cmake/source/augeas/generated/linux/aarch64/code/parser.c
new file mode 100644
index 00000000000..6991447f67e
--- /dev/null
+++ b/libraries/cmake/source/augeas/generated/linux/aarch64/code/parser.c
@@ -0,0 +1,2493 @@
+/* A Bison parser, made by GNU Bison 3.0.4. */
+
+/* Bison implementation for Yacc-like parsers in C
+
+ Copyright (C) 1984, 1989-1990, 2000-2015 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. */
+
+/* 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. */
+#define YYBISON 1
+
+/* Bison version. */
+#define YYBISON_VERSION "3.0.4"
+
+/* Skeleton name. */
+#define YYSKELETON_NAME "yacc.c"
+
+/* Pure parsers. */
+#define YYPURE 1
+
+/* Push parsers. */
+#define YYPUSH 0
+
+/* Pull parsers. */
+#define YYPULL 1
+
+
+/* Substitute the variable and function names. */
+#define yyparse augl_parse
+#define yylex augl_lex
+#define yyerror augl_error
+#define yydebug augl_debug
+#define yynerrs augl_nerrs
+
+
+/* Copy the first part of user declarations. */
+#line 1 "parser.y" /* yacc.c:339 */
+
+
+#include
+
+#include "internal.h"
+#include "syntax.h"
+#include "list.h"
+#include "errcode.h"
+#include
+
+/* Work around a problem on FreeBSD where Bison looks for _STDLIB_H
+ * to see if stdlib.h has been included, but the system includes
+ * use _STDLIB_H_
+ */
+#if HAVE_STDLIB_H && ! defined _STDLIB_H
+# include
+# define _STDLIB_H 1
+#endif
+
+#define YYDEBUG 1
+
+int augl_parse_file(struct augeas *aug, const char *name, struct term **term);
+
+typedef void *yyscan_t;
+typedef struct info YYLTYPE;
+#define YYLTYPE_IS_DECLARED 1
+/* The lack of reference counting on filename is intentional */
+# define YYLLOC_DEFAULT(Current, Rhs, N) \
+ do { \
+ (Current).filename = augl_get_info(scanner)->filename; \
+ (Current).error = augl_get_info(scanner)->error; \
+ 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)
+
+#line 117 "parser.c" /* yacc.c:339 */
+
+# ifndef YY_NULLPTR
+# if defined __cplusplus && 201103L <= __cplusplus
+# define YY_NULLPTR nullptr
+# else
+# define YY_NULLPTR 0
+# endif
+# endif
+
+/* Enabling verbose error messages. */
+#ifdef YYERROR_VERBOSE
+# undef YYERROR_VERBOSE
+# define YYERROR_VERBOSE 1
+#else
+# define YYERROR_VERBOSE 1
+#endif
+
+/* In a future release of Bison, this section will be replaced
+ by #include "y.tab.h". */
+#ifndef YY_AUGL_PARSER_H_INCLUDED
+# define YY_AUGL_PARSER_H_INCLUDED
+/* Debug traces. */
+#ifndef YYDEBUG
+# define YYDEBUG 0
+#endif
+#if YYDEBUG
+extern int augl_debug;
+#endif
+
+/* Token type. */
+#ifndef YYTOKENTYPE
+# define YYTOKENTYPE
+ enum yytokentype
+ {
+ DQUOTED = 258,
+ REGEXP = 259,
+ LIDENT = 260,
+ UIDENT = 261,
+ QIDENT = 262,
+ ARROW = 263,
+ KW_MODULE = 264,
+ KW_AUTOLOAD = 265,
+ KW_LET = 266,
+ KW_LET_REC = 267,
+ KW_IN = 268,
+ KW_STRING = 269,
+ KW_REGEXP = 270,
+ KW_LENS = 271,
+ KW_TEST = 272,
+ KW_GET = 273,
+ KW_PUT = 274,
+ KW_AFTER = 275
+ };
+#endif
+/* Tokens. */
+#define DQUOTED 258
+#define REGEXP 259
+#define LIDENT 260
+#define UIDENT 261
+#define QIDENT 262
+#define ARROW 263
+#define KW_MODULE 264
+#define KW_AUTOLOAD 265
+#define KW_LET 266
+#define KW_LET_REC 267
+#define KW_IN 268
+#define KW_STRING 269
+#define KW_REGEXP 270
+#define KW_LENS 271
+#define KW_TEST 272
+#define KW_GET 273
+#define KW_PUT 274
+#define KW_AFTER 275
+
+/* Value type. */
+#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
+
+union YYSTYPE
+{
+#line 89 "parser.y" /* yacc.c:355 */
+
+ struct term *term;
+ struct type *type;
+ struct ident *ident;
+ struct tree *tree;
+ char *string;
+ struct {
+ int nocase;
+ char *pattern;
+ } regexp;
+ int intval;
+ enum quant_tag quant;
+
+#line 211 "parser.c" /* yacc.c:355 */
+};
+
+typedef union YYSTYPE YYSTYPE;
+# define YYSTYPE_IS_TRIVIAL 1
+# define YYSTYPE_IS_DECLARED 1
+#endif
+
+/* 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 augl_parse (struct term **term, yyscan_t scanner);
+/* "%code provides" blocks. */
+#line 46 "parser.y" /* yacc.c:355 */
+
+#include "info.h"
+
+/* Track custom scanner state */
+struct state {
+ struct info *info;
+ unsigned int comment_depth;
+};
+
+
+#line 248 "parser.c" /* yacc.c:355 */
+
+#endif /* !YY_AUGL_PARSER_H_INCLUDED */
+
+/* Copy the second part of user declarations. */
+#line 114 "parser.y" /* yacc.c:358 */
+
+/* Lexer */
+extern int augl_lex (YYSTYPE * yylval_param,struct info * yylloc_param ,yyscan_t yyscanner);
+int augl_init_lexer(struct state *state, yyscan_t * scanner);
+void augl_close_lexer(yyscan_t *scanner);
+int augl_lex_destroy (yyscan_t yyscanner );
+int augl_get_lineno (yyscan_t yyscanner );
+int augl_get_column (yyscan_t yyscanner);
+struct info *augl_get_info(yyscan_t yyscanner);
+char *augl_get_text (yyscan_t yyscanner );
+
+static void augl_error(struct info *locp, struct term **term,
+ yyscan_t scanner, const char *s);
+
+/* TERM construction */
+ static struct info *clone_info(struct info *locp);
+ static struct term *make_module(char *ident, char *autoload,
+ struct term *decls,
+ struct info *locp);
+
+ static struct term *make_bind(char *ident, struct term *params,
+ struct term *exp, struct term *decls,
+ struct info *locp);
+ static struct term *make_bind_rec(char *ident, struct term *exp,
+ struct term *decls, struct info *locp);
+ static struct term *make_let(char *ident, struct term *params,
+ struct term *exp, struct term *body,
+ struct info *locp);
+ static struct term *make_binop(enum term_tag tag,
+ struct term *left, struct term *right,
+ struct info *locp);
+ static struct term *make_unop(enum term_tag tag,
+ struct term *exp, struct info *locp);
+ static struct term *make_ident(char *qname, struct info *locp);
+ static struct term *make_unit_term(struct info *locp);
+ static struct term *make_string_term(char *value, struct info *locp);
+ static struct term *make_regexp_term(char *pattern,
+ int nocase, struct info *locp);
+ static struct term *make_rep(struct term *exp, enum quant_tag quant,
+ struct info *locp);
+
+ static struct term *make_get_test(struct term *lens, struct term *arg,
+ struct info *info);
+ static struct term *make_put_test(struct term *lens, struct term *arg,
+ struct term *cmds, struct info *info);
+ static struct term *make_test(struct term *test, struct term *result,
+ enum test_result_tag tr_tag,
+ struct term *decls, struct info *locp);
+ static struct term *make_tree_value(struct tree *, struct info*);
+ static struct tree *tree_concat(struct tree *, struct tree *);
+
+#define LOC_MERGE(a, b, c) \
+ do { \
+ (a).filename = (b).filename; \
+ (a).first_line = (b).first_line; \
+ (a).first_column = (b).first_column; \
+ (a).last_line = (c).last_line; \
+ (a).last_column = (c).last_column; \
+ (a).error = (b).error; \
+ } while(0);
+
+
+#line 316 "parser.c" /* yacc.c:358 */
+
+#ifdef short
+# undef short
+#endif
+
+#ifdef YYTYPE_UINT8
+typedef YYTYPE_UINT8 yytype_uint8;
+#else
+typedef unsigned char yytype_uint8;
+#endif
+
+#ifdef YYTYPE_INT8
+typedef YYTYPE_INT8 yytype_int8;
+#else
+typedef signed char yytype_int8;
+#endif
+
+#ifdef YYTYPE_UINT16
+typedef YYTYPE_UINT16 yytype_uint16;
+#else
+typedef unsigned short int yytype_uint16;
+#endif
+
+#ifdef YYTYPE_INT16
+typedef YYTYPE_INT16 yytype_int16;
+#else
+typedef short int yytype_int16;
+#endif
+
+#ifndef YYSIZE_T
+# ifdef __SIZE_TYPE__
+# define YYSIZE_T __SIZE_TYPE__
+# elif defined size_t
+# define YYSIZE_T size_t
+# elif ! defined YYSIZE_T
+# include /* INFRINGES ON USER NAME SPACE */
+# define YYSIZE_T size_t
+# else
+# define YYSIZE_T unsigned int
+# endif
+#endif
+
+#define YYSIZE_MAXIMUM ((YYSIZE_T) -1)
+
+#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
+# if (defined __GNUC__ \
+ && (2 < __GNUC__ || (__GNUC__ == 2 && 96 <= __GNUC_MINOR__))) \
+ || defined __SUNPRO_C && 0x5110 <= __SUNPRO_C
+# define YY_ATTRIBUTE(Spec) __attribute__(Spec)
+# else
+# define YY_ATTRIBUTE(Spec) /* empty */
+# endif
+#endif
+
+#ifndef YY_ATTRIBUTE_PURE
+# define YY_ATTRIBUTE_PURE YY_ATTRIBUTE ((__pure__))
+#endif
+
+#ifndef YY_ATTRIBUTE_UNUSED
+# define YY_ATTRIBUTE_UNUSED YY_ATTRIBUTE ((__unused__))
+#endif
+
+#if !defined _Noreturn \
+ && (!defined __STDC_VERSION__ || __STDC_VERSION__ < 201112)
+# if defined _MSC_VER && 1200 <= _MSC_VER
+# define _Noreturn __declspec (noreturn)
+# else
+# define _Noreturn YY_ATTRIBUTE ((__noreturn__))
+# endif
+#endif
+
+/* Suppress unused-variable warnings by "using" E. */
+#if ! defined lint || defined __GNUC__
+# define YYUSE(E) ((void) (E))
+#else
+# define YYUSE(E) /* empty */
+#endif
+
+#if defined __GNUC__ && 407 <= __GNUC__ * 100 + __GNUC_MINOR__
+/* Suppress an incorrect diagnostic about yylval being uninitialized. */
+# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
+ _Pragma ("GCC diagnostic push") \
+ _Pragma ("GCC diagnostic ignored \"-Wuninitialized\"")\
+ _Pragma ("GCC diagnostic ignored \"-Wmaybe-uninitialized\"")
+# 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 yyoverflow || YYERROR_VERBOSE
+
+/* 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 || YYERROR_VERBOSE */
+
+
+#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
+{
+ yytype_int16 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 (sizeof (union yyalloc) - 1)
+
+/* The size of an array large to enough to hold all stacks, each with
+ N elements. */
+# define YYSTACK_BYTES(N) \
+ ((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE) + sizeof (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 \
+ { \
+ YYSIZE_T yynewbytes; \
+ YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \
+ Stack = &yyptr->Stack_alloc; \
+ yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \
+ yyptr += yynewbytes / sizeof (*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, (Count) * sizeof (*(Src)))
+# else
+# define YYCOPY(Dst, Src, Count) \
+ do \
+ { \
+ YYSIZE_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 4
+/* YYLAST -- Last index in YYTABLE. */
+#define YYLAST 129
+
+/* YYNTOKENS -- Number of terminals. */
+#define YYNTOKENS 36
+/* YYNNTS -- Number of nonterminals. */
+#define YYNNTS 25
+/* YYNRULES -- Number of rules. */
+#define YYNRULES 61
+/* YYNSTATES -- Number of states. */
+#define YYNSTATES 113
+
+/* YYTRANSLATE[YYX] -- Symbol number corresponding to YYX as returned
+ by yylex, with out-of-bounds checking. */
+#define YYUNDEFTOK 2
+#define YYMAXUTOK 275
+
+#define YYTRANSLATE(YYX) \
+ ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK)
+
+/* YYTRANSLATE[TOKEN-NUM] -- Symbol number corresponding to TOKEN-NUM
+ as returned by yylex, without out-of-bounds checking. */
+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, 2, 2, 2, 2, 2, 2, 2,
+ 28, 29, 23, 32, 2, 26, 27, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 33, 24,
+ 2, 21, 2, 22, 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, 30, 2, 31, 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, 34, 25, 35, 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, 2, 1, 2, 3, 4,
+ 5, 6, 7, 8, 9, 10, 11, 12, 13, 14,
+ 15, 16, 17, 18, 19, 20
+};
+
+#if YYDEBUG
+ /* YYRLINE[YYN] -- Source line where rule number YYN was defined. */
+static const yytype_uint16 yyrline[] =
+{
+ 0, 179, 179, 182, 185, 187, 192, 197, 202, 208,
+ 212, 214, 217, 219, 223, 228, 230, 232, 235, 237,
+ 239, 242, 244, 247, 249, 252, 254, 257, 259, 261,
+ 263, 265, 267, 270, 272, 275, 277, 279, 282, 284,
+ 286, 288, 291, 294, 296, 299, 301, 303, 306, 308,
+ 311, 313, 315, 317, 320, 322, 325, 330, 332, 336,
+ 340, 342
+};
+#endif
+
+#if YYDEBUG || YYERROR_VERBOSE || 1
+/* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM.
+ First, the terminals, then, starting at YYNTOKENS, nonterminals. */
+static const char *const yytname[] =
+{
+ "$end", "error", "$undefined", "DQUOTED", "REGEXP", "LIDENT", "UIDENT",
+ "QIDENT", "ARROW", "KW_MODULE", "KW_AUTOLOAD", "KW_LET", "KW_LET_REC",
+ "KW_IN", "KW_STRING", "KW_REGEXP", "KW_LENS", "KW_TEST", "KW_GET",
+ "KW_PUT", "KW_AFTER", "'='", "'?'", "'*'", "';'", "'|'", "'-'", "'.'",
+ "'('", "')'", "'['", "']'", "'+'", "':'", "'{'", "'}'", "$accept",
+ "start", "autoload", "decls", "test_exp", "test_special_res", "exp",
+ "composeexp", "unionexp", "minusexp", "catexp", "appexp", "aexp", "rexp",
+ "rep", "qid", "param_list", "param", "id", "type", "atype", "tree_const",
+ "tree_const2", "tree_branch", "tree_label", YY_NULLPTR
+};
+#endif
+
+# ifdef YYPRINT
+/* YYTOKNUM[NUM] -- (External) token number corresponding to the
+ (internal) symbol number NUM (which must be that of a token). */
+static const yytype_uint16 yytoknum[] =
+{
+ 0, 256, 257, 258, 259, 260, 261, 262, 263, 264,
+ 265, 266, 267, 268, 269, 270, 271, 272, 273, 274,
+ 275, 61, 63, 42, 59, 124, 45, 46, 40, 41,
+ 91, 93, 43, 58, 123, 125
+};
+# endif
+
+#define YYPACT_NINF -90
+
+#define yypact_value_is_default(Yystate) \
+ (!!((Yystate) == (-90)))
+
+#define YYTABLE_NINF -1
+
+#define yytable_value_is_error(Yytable_value) \
+ 0
+
+ /* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
+ STATE-NUM. */
+static const yytype_int8 yypact[] =
+{
+ -1, 8, 16, -4, -90, 14, 26, 53, -90, 27,
+ 29, 92, -90, 11, 25, -90, -90, -90, -90, -90,
+ -90, 50, 55, 28, -6, -90, 1, 30, 11, 55,
+ 38, -90, 44, 34, 52, 57, 51, 59, 92, 49,
+ -90, 64, 56, 22, 55, 92, -90, -90, -90, 60,
+ 55, -90, 53, 11, -90, 65, 80, -90, 87, 92,
+ 92, 92, -90, -90, -90, -90, -90, 44, -90, -90,
+ -90, 53, 53, -90, 82, -5, 53, -90, 83, -90,
+ 100, 73, 57, 51, 59, 92, 74, -90, -90, 55,
+ -90, -90, -90, -5, 79, 104, -90, 55, -90, 44,
+ -90, -90, 84, -90, -5, 101, 73, 81, -90, -90,
+ 55, -90, -90
+};
+
+ /* 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_uint8 yydefact[] =
+{
+ 0, 0, 0, 0, 1, 4, 0, 9, 3, 0,
+ 0, 0, 2, 43, 0, 28, 29, 38, 39, 40,
+ 41, 0, 0, 0, 0, 27, 0, 0, 43, 0,
+ 0, 32, 61, 0, 15, 17, 19, 22, 24, 34,
+ 26, 20, 0, 0, 0, 0, 45, 46, 47, 0,
+ 0, 42, 9, 43, 60, 0, 57, 30, 0, 0,
+ 0, 0, 25, 37, 35, 36, 33, 61, 31, 12,
+ 13, 9, 9, 10, 0, 0, 9, 6, 0, 55,
+ 0, 58, 16, 18, 21, 23, 0, 8, 7, 0,
+ 50, 51, 52, 0, 0, 49, 5, 0, 57, 61,
+ 54, 11, 0, 44, 0, 0, 59, 0, 53, 48,
+ 0, 56, 14
+};
+
+ /* YYPGOTO[NTERM-NUM]. */
+static const yytype_int8 yypgoto[] =
+{
+ -90, -90, -90, -34, -90, -90, -22, -90, 61, 66,
+ 58, 62, -9, -37, -90, -90, -23, -90, -90, -89,
+ -90, -90, 31, -64, -90
+};
+
+ /* YYDEFGOTO[NTERM-NUM]. */
+static const yytype_int8 yydefgoto[] =
+{
+ -1, 2, 7, 12, 23, 71, 33, 34, 35, 36,
+ 37, 38, 39, 40, 66, 25, 27, 28, 49, 94,
+ 95, 41, 81, 55, 56
+};
+
+ /* 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_uint8 yytable[] =
+{
+ 42, 62, 24, 86, 102, 51, 46, 52, 1, 90,
+ 91, 92, 44, 45, 3, 109, 4, 5, 77, 47,
+ 48, 72, 73, 93, 6, 15, 16, 17, 76, 18,
+ 78, 8, 13, 30, 14, 107, 74, 87, 88, 26,
+ 19, 20, 96, 53, 69, 70, 29, 54, 62, 43,
+ 21, 50, 22, 15, 16, 17, 32, 18, 15, 16,
+ 17, 30, 18, 57, 9, 10, 30, 101, 19, 20,
+ 11, 63, 64, 19, 20, 105, 58, 60, 21, 31,
+ 22, 65, 59, 21, 32, 22, 61, 68, 112, 32,
+ 15, 16, 17, 75, 18, 15, 16, 17, 67, 18,
+ 79, 80, 89, 98, 97, 19, 20, 99, 103, 100,
+ 19, 20, 104, 108, 110, 21, 111, 22, 84, 82,
+ 21, 32, 22, 85, 0, 83, 0, 0, 0, 106
+};
+
+static const yytype_int8 yycheck[] =
+{
+ 22, 38, 11, 67, 93, 28, 5, 29, 9, 14,
+ 15, 16, 18, 19, 6, 104, 0, 21, 52, 18,
+ 19, 43, 44, 28, 10, 3, 4, 5, 50, 7,
+ 53, 5, 5, 11, 5, 99, 45, 71, 72, 28,
+ 18, 19, 76, 5, 22, 23, 21, 3, 85, 21,
+ 28, 21, 30, 3, 4, 5, 34, 7, 3, 4,
+ 5, 11, 7, 29, 11, 12, 11, 89, 18, 19,
+ 17, 22, 23, 18, 19, 97, 24, 26, 28, 29,
+ 30, 32, 25, 28, 34, 30, 27, 31, 110, 34,
+ 3, 4, 5, 33, 7, 3, 4, 5, 34, 7,
+ 35, 21, 20, 3, 21, 18, 19, 34, 29, 35,
+ 18, 19, 8, 29, 13, 28, 35, 30, 60, 58,
+ 28, 34, 30, 61, -1, 59, -1, -1, -1, 98
+};
+
+ /* YYSTOS[STATE-NUM] -- The (internal number of the) accessing
+ symbol of state STATE-NUM. */
+static const yytype_uint8 yystos[] =
+{
+ 0, 9, 37, 6, 0, 21, 10, 38, 5, 11,
+ 12, 17, 39, 5, 5, 3, 4, 5, 7, 18,
+ 19, 28, 30, 40, 48, 51, 28, 52, 53, 21,
+ 11, 29, 34, 42, 43, 44, 45, 46, 47, 48,
+ 49, 57, 42, 21, 18, 19, 5, 18, 19, 54,
+ 21, 52, 42, 5, 3, 59, 60, 29, 24, 25,
+ 26, 27, 49, 22, 23, 32, 50, 34, 31, 22,
+ 23, 41, 42, 42, 48, 33, 42, 39, 52, 35,
+ 21, 58, 44, 45, 46, 47, 59, 39, 39, 20,
+ 14, 15, 16, 28, 55, 56, 39, 21, 3, 34,
+ 35, 42, 55, 29, 8, 42, 58, 59, 29, 55,
+ 13, 35, 42
+};
+
+ /* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */
+static const yytype_uint8 yyr1[] =
+{
+ 0, 36, 37, 38, 38, 39, 39, 39, 39, 39,
+ 40, 40, 41, 41, 42, 42, 43, 43, 44, 44,
+ 44, 45, 45, 46, 46, 47, 47, 48, 48, 48,
+ 48, 48, 48, 49, 49, 50, 50, 50, 51, 51,
+ 51, 51, 52, 52, 53, 54, 54, 54, 55, 55,
+ 56, 56, 56, 56, 57, 57, 58, 58, 59, 59,
+ 60, 60
+};
+
+ /* YYR2[YYN] -- Number of symbols on the right hand side of rule YYN. */
+static const yytype_uint8 yyr2[] =
+{
+ 0, 2, 5, 2, 0, 6, 5, 5, 5, 0,
+ 3, 5, 1, 1, 7, 1, 3, 1, 3, 1,
+ 1, 3, 1, 3, 1, 2, 1, 1, 1, 1,
+ 3, 3, 2, 2, 1, 1, 1, 1, 1, 1,
+ 1, 1, 2, 0, 5, 1, 1, 1, 3, 1,
+ 1, 1, 1, 3, 4, 3, 4, 0, 2, 4,
+ 1, 0
+};
+
+
+#define yyerrok (yyerrstatus = 0)
+#define yyclearin (yychar = YYEMPTY)
+#define YYEMPTY (-2)
+#define YYEOF 0
+
+#define YYACCEPT goto yyacceptlab
+#define YYABORT goto yyabortlab
+#define YYERROR goto yyerrorlab
+
+
+#define YYRECOVERING() (!!yyerrstatus)
+
+#define YYBACKUP(Token, Value) \
+do \
+ if (yychar == YYEMPTY) \
+ { \
+ yychar = (Token); \
+ yylval = (Value); \
+ YYPOPSTACK (yylen); \
+ yystate = *yyssp; \
+ goto yybackup; \
+ } \
+ else \
+ { \
+ yyerror (&yylloc, term, scanner, YY_("syntax error: cannot back up")); \
+ YYERROR; \
+ } \
+while (0)
+
+/* Error token number */
+#define YYTERROR 1
+#define YYERRCODE 256
+
+
+/* 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)
+
+
+/* YY_LOCATION_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 YY_LOCATION_PRINT
+# if defined YYLTYPE_IS_TRIVIAL && YYLTYPE_IS_TRIVIAL
+
+/* Print *YYLOCP on YYO. Private, do not rely on its existence. */
+
+YY_ATTRIBUTE_UNUSED
+static unsigned
+yy_location_print_ (FILE *yyo, YYLTYPE const * const yylocp)
+{
+ unsigned 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 YY_LOCATION_PRINT(File, Loc) \
+ yy_location_print_ (File, &(Loc))
+
+# else
+# define YY_LOCATION_PRINT(File, Loc) ((void) 0)
+# endif
+#endif
+
+
+# define YY_SYMBOL_PRINT(Title, Type, Value, Location) \
+do { \
+ if (yydebug) \
+ { \
+ YYFPRINTF (stderr, "%s ", Title); \
+ yy_symbol_print (stderr, \
+ Type, Value, Location, term, scanner); \
+ YYFPRINTF (stderr, "\n"); \
+ } \
+} while (0)
+
+
+/*----------------------------------------.
+| Print this symbol's value on YYOUTPUT. |
+`----------------------------------------*/
+
+static void
+yy_symbol_value_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep, YYLTYPE const * const yylocationp, struct term **term, yyscan_t scanner)
+{
+ FILE *yyo = yyoutput;
+ YYUSE (yyo);
+ YYUSE (yylocationp);
+ YYUSE (term);
+ YYUSE (scanner);
+ if (!yyvaluep)
+ return;
+# ifdef YYPRINT
+ if (yytype < YYNTOKENS)
+ YYPRINT (yyoutput, yytoknum[yytype], *yyvaluep);
+# endif
+ YYUSE (yytype);
+}
+
+
+/*--------------------------------.
+| Print this symbol on YYOUTPUT. |
+`--------------------------------*/
+
+static void
+yy_symbol_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep, YYLTYPE const * const yylocationp, struct term **term, yyscan_t scanner)
+{
+ YYFPRINTF (yyoutput, "%s %s (",
+ yytype < YYNTOKENS ? "token" : "nterm", yytname[yytype]);
+
+ YY_LOCATION_PRINT (yyoutput, *yylocationp);
+ YYFPRINTF (yyoutput, ": ");
+ yy_symbol_value_print (yyoutput, yytype, yyvaluep, yylocationp, term, scanner);
+ YYFPRINTF (yyoutput, ")");
+}
+
+/*------------------------------------------------------------------.
+| yy_stack_print -- Print the state stack from its BOTTOM up to its |
+| TOP (included). |
+`------------------------------------------------------------------*/
+
+static void
+yy_stack_print (yytype_int16 *yybottom, yytype_int16 *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 (yytype_int16 *yyssp, YYSTYPE *yyvsp, YYLTYPE *yylsp, int yyrule, struct term **term, yyscan_t scanner)
+{
+ unsigned long int yylno = yyrline[yyrule];
+ int yynrhs = yyr2[yyrule];
+ int yyi;
+ YYFPRINTF (stderr, "Reducing stack by rule %d (line %lu):\n",
+ yyrule - 1, yylno);
+ /* The symbols being reduced. */
+ for (yyi = 0; yyi < yynrhs; yyi++)
+ {
+ YYFPRINTF (stderr, " $%d = ", yyi + 1);
+ yy_symbol_print (stderr,
+ yystos[yyssp[yyi + 1 - yynrhs]],
+ &(yyvsp[(yyi + 1) - (yynrhs)])
+ , &(yylsp[(yyi + 1) - (yynrhs)]) , term, scanner);
+ YYFPRINTF (stderr, "\n");
+ }
+}
+
+# define YY_REDUCE_PRINT(Rule) \
+do { \
+ if (yydebug) \
+ yy_reduce_print (yyssp, yyvsp, yylsp, Rule, term, scanner); \
+} while (0)
+
+/* Nonzero means print parse trace. It is left uninitialized so that
+ multiple parsers can coexist. */
+int yydebug;
+#else /* !YYDEBUG */
+# define YYDPRINTF(Args)
+# define YY_SYMBOL_PRINT(Title, Type, 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
+
+
+#if YYERROR_VERBOSE
+
+# ifndef yystrlen
+# if defined __GLIBC__ && defined _STRING_H
+# define yystrlen strlen
+# else
+/* Return the length of YYSTR. */
+static YYSIZE_T
+yystrlen (const char *yystr)
+{
+ YYSIZE_T yylen;
+ for (yylen = 0; yystr[yylen]; yylen++)
+ continue;
+ return yylen;
+}
+# endif
+# endif
+
+# ifndef yystpcpy
+# if defined __GLIBC__ && defined _STRING_H && defined _GNU_SOURCE
+# define yystpcpy stpcpy
+# else
+/* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in
+ YYDEST. */
+static char *
+yystpcpy (char *yydest, const char *yysrc)
+{
+ char *yyd = yydest;
+ const char *yys = yysrc;
+
+ while ((*yyd++ = *yys++) != '\0')
+ continue;
+
+ return yyd - 1;
+}
+# endif
+# endif
+
+# ifndef yytnamerr
+/* Copy to YYRES the contents of YYSTR after stripping away unnecessary
+ quotes and backslashes, so that it's suitable for yyerror. The
+ heuristic is that double-quoting is unnecessary unless the string
+ contains an apostrophe, a comma, or backslash (other than
+ backslash-backslash). YYSTR is taken from yytname. If YYRES is
+ null, do not copy; instead, return the length of what the result
+ would have been. */
+static YYSIZE_T
+yytnamerr (char *yyres, const char *yystr)
+{
+ if (*yystr == '"')
+ {
+ YYSIZE_T yyn = 0;
+ char const *yyp = yystr;
+
+ for (;;)
+ switch (*++yyp)
+ {
+ case '\'':
+ case ',':
+ goto do_not_strip_quotes;
+
+ case '\\':
+ if (*++yyp != '\\')
+ goto do_not_strip_quotes;
+ /* Fall through. */
+ default:
+ if (yyres)
+ yyres[yyn] = *yyp;
+ yyn++;
+ break;
+
+ case '"':
+ if (yyres)
+ yyres[yyn] = '\0';
+ return yyn;
+ }
+ do_not_strip_quotes: ;
+ }
+
+ if (! yyres)
+ return yystrlen (yystr);
+
+ return yystpcpy (yyres, yystr) - yyres;
+}
+# endif
+
+/* Copy into *YYMSG, which is of size *YYMSG_ALLOC, an error message
+ about the unexpected token YYTOKEN for the state stack whose top is
+ YYSSP.
+
+ Return 0 if *YYMSG was successfully written. Return 1 if *YYMSG is
+ not large enough to hold the message. In that case, also set
+ *YYMSG_ALLOC to the required number of bytes. Return 2 if the
+ required number of bytes is too large to store. */
+static int
+yysyntax_error (YYSIZE_T *yymsg_alloc, char **yymsg,
+ yytype_int16 *yyssp, int yytoken)
+{
+ YYSIZE_T yysize0 = yytnamerr (YY_NULLPTR, yytname[yytoken]);
+ YYSIZE_T yysize = yysize0;
+ enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 };
+ /* Internationalized format string. */
+ const char *yyformat = YY_NULLPTR;
+ /* Arguments of yyformat. */
+ char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM];
+ /* Number of reported tokens (one for the "unexpected", one per
+ "expected"). */
+ int yycount = 0;
+
+ /* There are many possibilities here to consider:
+ - If this state is a consistent state with a default action, then
+ the only way this function was invoked is if the default action
+ is an error action. In that case, don't check for expected
+ tokens because there are none.
+ - The only way there can be no lookahead present (in yychar) is if
+ this state is a consistent state with a default action. Thus,
+ detecting the absence of a lookahead is sufficient to determine
+ that there is no unexpected or expected token to report. In that
+ case, just report a simple "syntax error".
+ - Don't assume there isn't a lookahead just because this state is a
+ consistent state with a default action. There might have been a
+ previous inconsistent state, consistent state with a non-default
+ action, or user semantic action that manipulated yychar.
+ - Of course, the expected token list depends on states to have
+ correct lookahead information, and it depends on the parser not
+ to perform extra reductions after fetching a lookahead from the
+ scanner and before detecting a syntax error. Thus, state merging
+ (from LALR or IELR) and default reductions corrupt the expected
+ token list. However, the list is correct for canonical LR with
+ one exception: it will still contain any token that will not be
+ accepted due to an error action in a later state.
+ */
+ if (yytoken != YYEMPTY)
+ {
+ int yyn = yypact[*yyssp];
+ yyarg[yycount++] = yytname[yytoken];
+ if (!yypact_value_is_default (yyn))
+ {
+ /* Start YYX at -YYN if negative to avoid negative indexes in
+ YYCHECK. In other words, skip the first -YYN actions for
+ this state because they are default actions. */
+ int yyxbegin = yyn < 0 ? -yyn : 0;
+ /* Stay within bounds of both yycheck and yytname. */
+ int yychecklim = YYLAST - yyn + 1;
+ int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS;
+ int yyx;
+
+ for (yyx = yyxbegin; yyx < yyxend; ++yyx)
+ if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR
+ && !yytable_value_is_error (yytable[yyx + yyn]))
+ {
+ if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM)
+ {
+ yycount = 1;
+ yysize = yysize0;
+ break;
+ }
+ yyarg[yycount++] = yytname[yyx];
+ {
+ YYSIZE_T yysize1 = yysize + yytnamerr (YY_NULLPTR, yytname[yyx]);
+ if (! (yysize <= yysize1
+ && yysize1 <= YYSTACK_ALLOC_MAXIMUM))
+ return 2;
+ yysize = yysize1;
+ }
+ }
+ }
+ }
+
+ switch (yycount)
+ {
+# define YYCASE_(N, S) \
+ case N: \
+ yyformat = S; \
+ break
+ YYCASE_(0, YY_("syntax error"));
+ YYCASE_(1, YY_("syntax error, unexpected %s"));
+ YYCASE_(2, YY_("syntax error, unexpected %s, expecting %s"));
+ YYCASE_(3, YY_("syntax error, unexpected %s, expecting %s or %s"));
+ YYCASE_(4, YY_("syntax error, unexpected %s, expecting %s or %s or %s"));
+ YYCASE_(5, YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s"));
+# undef YYCASE_
+ }
+
+ {
+ YYSIZE_T yysize1 = yysize + yystrlen (yyformat);
+ if (! (yysize <= yysize1 && yysize1 <= YYSTACK_ALLOC_MAXIMUM))
+ return 2;
+ yysize = yysize1;
+ }
+
+ if (*yymsg_alloc < yysize)
+ {
+ *yymsg_alloc = 2 * yysize;
+ if (! (yysize <= *yymsg_alloc
+ && *yymsg_alloc <= YYSTACK_ALLOC_MAXIMUM))
+ *yymsg_alloc = YYSTACK_ALLOC_MAXIMUM;
+ return 1;
+ }
+
+ /* Avoid sprintf, as that infringes on the user's name space.
+ Don't have undefined behavior even if the translation
+ produced a string with the wrong number of "%s"s. */
+ {
+ char *yyp = *yymsg;
+ int yyi = 0;
+ while ((*yyp = *yyformat) != '\0')
+ if (*yyp == '%' && yyformat[1] == 's' && yyi < yycount)
+ {
+ yyp += yytnamerr (yyp, yyarg[yyi++]);
+ yyformat += 2;
+ }
+ else
+ {
+ yyp++;
+ yyformat++;
+ }
+ }
+ return 0;
+}
+#endif /* YYERROR_VERBOSE */
+
+/*-----------------------------------------------.
+| Release the memory associated to this symbol. |
+`-----------------------------------------------*/
+
+static void
+yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep, YYLTYPE *yylocationp, struct term **term, yyscan_t scanner)
+{
+ YYUSE (yyvaluep);
+ YYUSE (yylocationp);
+ YYUSE (term);
+ YYUSE (scanner);
+ if (!yymsg)
+ yymsg = "Deleting";
+ YY_SYMBOL_PRINT (yymsg, yytype, yyvaluep, yylocationp);
+
+ YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
+ YYUSE (yytype);
+ YY_IGNORE_MAYBE_UNINITIALIZED_END
+}
+
+
+
+
+/*----------.
+| yyparse. |
+`----------*/
+
+int
+yyparse (struct term **term, yyscan_t scanner)
+{
+/* The lookahead symbol. */
+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;
+
+ int yystate;
+ /* Number of tokens to shift before error messages enabled. */
+ int yyerrstatus;
+
+ /* The stacks and their tools:
+ 'yyss': related to states.
+ 'yyvs': related to semantic values.
+ 'yyls': related to locations.
+
+ Refer to the stacks through separate pointers, to allow yyoverflow
+ to reallocate them elsewhere. */
+
+ /* The state stack. */
+ yytype_int16 yyssa[YYINITDEPTH];
+ yytype_int16 *yyss;
+ yytype_int16 *yyssp;
+
+ /* The semantic value stack. */
+ YYSTYPE yyvsa[YYINITDEPTH];
+ YYSTYPE *yyvs;
+ YYSTYPE *yyvsp;
+
+ /* The location stack. */
+ YYLTYPE yylsa[YYINITDEPTH];
+ YYLTYPE *yyls;
+ YYLTYPE *yylsp;
+
+ /* The locations where the error started and ended. */
+ YYLTYPE yyerror_range[3];
+
+ YYSIZE_T yystacksize;
+
+ int yyn;
+ int yyresult;
+ /* Lookahead token as an internal (translated) token number. */
+ int yytoken = 0;
+ /* The variables used to return semantic value and location from the
+ action routines. */
+ YYSTYPE yyval;
+ YYLTYPE yyloc;
+
+#if YYERROR_VERBOSE
+ /* Buffer for error messages, and its allocated size. */
+ char yymsgbuf[128];
+ char *yymsg = yymsgbuf;
+ YYSIZE_T yymsg_alloc = sizeof yymsgbuf;
+#endif
+
+#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;
+
+ yyssp = yyss = yyssa;
+ yyvsp = yyvs = yyvsa;
+ yylsp = yyls = yylsa;
+ yystacksize = YYINITDEPTH;
+
+ YYDPRINTF ((stderr, "Starting parse\n"));
+
+ yystate = 0;
+ yyerrstatus = 0;
+ yynerrs = 0;
+ yychar = YYEMPTY; /* Cause a token to be read. */
+
+/* User initialization code. */
+#line 66 "parser.y" /* yacc.c:1429 */
+{
+ yylloc.first_line = 1;
+ yylloc.first_column = 0;
+ yylloc.last_line = 1;
+ yylloc.last_column = 0;
+ yylloc.filename = augl_get_info(scanner)->filename;
+ yylloc.error = augl_get_info(scanner)->error;
+}
+
+#line 1401 "parser.c" /* yacc.c:1429 */
+ 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:
+ *yyssp = yystate;
+
+ if (yyss + yystacksize - 1 <= yyssp)
+ {
+ /* Get the current used size of the three stacks, in elements. */
+ YYSIZE_T yysize = yyssp - yyss + 1;
+
+#ifdef 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. */
+ YYSTYPE *yyvs1 = yyvs;
+ yytype_int16 *yyss1 = yyss;
+ 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 * sizeof (*yyssp),
+ &yyvs1, yysize * sizeof (*yyvsp),
+ &yyls1, yysize * sizeof (*yylsp),
+ &yystacksize);
+
+ yyls = yyls1;
+ yyss = yyss1;
+ yyvs = yyvs1;
+ }
+#else /* no yyoverflow */
+# ifndef YYSTACK_RELOCATE
+ goto yyexhaustedlab;
+# else
+ /* Extend the stack our own way. */
+ if (YYMAXDEPTH <= yystacksize)
+ goto yyexhaustedlab;
+ yystacksize *= 2;
+ if (YYMAXDEPTH < yystacksize)
+ yystacksize = YYMAXDEPTH;
+
+ {
+ yytype_int16 *yyss1 = yyss;
+ union yyalloc *yyptr =
+ (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize));
+ if (! yyptr)
+ goto yyexhaustedlab;
+ 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
+#endif /* no yyoverflow */
+
+ yyssp = yyss + yysize - 1;
+ yyvsp = yyvs + yysize - 1;
+ yylsp = yyls + yysize - 1;
+
+ YYDPRINTF ((stderr, "Stack size increased to %lu\n",
+ (unsigned long int) yystacksize));
+
+ if (yyss + yystacksize - 1 <= yyssp)
+ YYABORT;
+ }
+
+ YYDPRINTF ((stderr, "Entering state %d\n", yystate));
+
+ 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 YYEMPTY or YYEOF or a valid lookahead symbol. */
+ if (yychar == YYEMPTY)
+ {
+ YYDPRINTF ((stderr, "Reading a token: "));
+ yychar = yylex (&yylval, &yylloc, scanner);
+ }
+
+ if (yychar <= YYEOF)
+ {
+ yychar = yytoken = YYEOF;
+ YYDPRINTF ((stderr, "Now at end of input.\n"));
+ }
+ 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);
+
+ /* Discard the shifted token. */
+ yychar = YYEMPTY;
+
+ yystate = yyn;
+ YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
+ *++yyvsp = yylval;
+ YY_IGNORE_MAYBE_UNINITIALIZED_END
+ *++yylsp = yylloc;
+ 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);
+ YY_REDUCE_PRINT (yyn);
+ switch (yyn)
+ {
+ case 2:
+#line 180 "parser.y" /* yacc.c:1646 */
+ { (*term) = make_module((yyvsp[-3].string), (yyvsp[-1].string), (yyvsp[0].term), &(yylsp[-4])); }
+#line 1590 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 3:
+#line 183 "parser.y" /* yacc.c:1646 */
+ { (yyval.string) = (yyvsp[0].string); }
+#line 1596 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 4:
+#line 185 "parser.y" /* yacc.c:1646 */
+ { (yyval.string) = NULL; }
+#line 1602 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 5:
+#line 188 "parser.y" /* yacc.c:1646 */
+ {
+ LOC_MERGE((yylsp[-5]), (yylsp[-5]), (yylsp[-1]));
+ (yyval.term) = make_bind((yyvsp[-4].string), (yyvsp[-3].term), (yyvsp[-1].term), (yyvsp[0].term), &(yylsp[-5]));
+ }
+#line 1611 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 6:
+#line 193 "parser.y" /* yacc.c:1646 */
+ {
+ LOC_MERGE((yylsp[-4]), (yylsp[-4]), (yylsp[-1]));
+ (yyval.term) = make_bind_rec((yyvsp[-3].string), (yyvsp[-1].term), (yyvsp[0].term), &(yylsp[-4]));
+ }
+#line 1620 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 7:
+#line 198 "parser.y" /* yacc.c:1646 */
+ {
+ LOC_MERGE((yylsp[-4]), (yylsp[-4]), (yylsp[-1]));
+ (yyval.term) = make_test((yyvsp[-3].term), (yyvsp[-1].term), TR_CHECK, (yyvsp[0].term), &(yylsp[-4]));
+ }
+#line 1629 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 8:
+#line 203 "parser.y" /* yacc.c:1646 */
+ {
+ LOC_MERGE((yylsp[-4]), (yylsp[-4]), (yylsp[-1]));
+ (yyval.term) = make_test((yyvsp[-3].term), NULL, (yyvsp[-1].intval), (yyvsp[0].term), &(yylsp[-4]));
+ }
+#line 1638 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 9:
+#line 208 "parser.y" /* yacc.c:1646 */
+ { (yyval.term) = NULL; }
+#line 1644 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 10:
+#line 213 "parser.y" /* yacc.c:1646 */
+ { (yyval.term) = make_get_test((yyvsp[-2].term), (yyvsp[0].term), &(yyloc)); }
+#line 1650 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 11:
+#line 215 "parser.y" /* yacc.c:1646 */
+ { (yyval.term) = make_put_test((yyvsp[-4].term), (yyvsp[-2].term), (yyvsp[0].term), &(yyloc)); }
+#line 1656 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 12:
+#line 218 "parser.y" /* yacc.c:1646 */
+ { (yyval.intval) = TR_PRINT; }
+#line 1662 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 13:
+#line 220 "parser.y" /* yacc.c:1646 */
+ { (yyval.intval) = TR_EXN; }
+#line 1668 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 14:
+#line 224 "parser.y" /* yacc.c:1646 */
+ {
+ LOC_MERGE((yylsp[-6]), (yylsp[-6]), (yylsp[-1]));
+ (yyval.term) = make_let((yyvsp[-5].string), (yyvsp[-4].term), (yyvsp[-2].term), (yyvsp[0].term), &(yylsp[-6]));
+ }
+#line 1677 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 16:
+#line 231 "parser.y" /* yacc.c:1646 */
+ { (yyval.term) = make_binop(A_COMPOSE, (yyvsp[-2].term), (yyvsp[0].term), &(yyloc)); }
+#line 1683 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 17:
+#line 233 "parser.y" /* yacc.c:1646 */
+ { (yyval.term) = (yyvsp[0].term); }
+#line 1689 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 18:
+#line 236 "parser.y" /* yacc.c:1646 */
+ { (yyval.term) = make_binop(A_UNION, (yyvsp[-2].term), (yyvsp[0].term), &(yyloc)); }
+#line 1695 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 19:
+#line 238 "parser.y" /* yacc.c:1646 */
+ { (yyval.term) = (yyvsp[0].term); }
+#line 1701 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 20:
+#line 240 "parser.y" /* yacc.c:1646 */
+ { (yyval.term) = make_tree_value((yyvsp[0].tree), &(yylsp[0])); }
+#line 1707 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 21:
+#line 243 "parser.y" /* yacc.c:1646 */
+ { (yyval.term) = make_binop(A_MINUS, (yyvsp[-2].term), (yyvsp[0].term), &(yyloc)); }
+#line 1713 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 22:
+#line 245 "parser.y" /* yacc.c:1646 */
+ { (yyval.term) = (yyvsp[0].term); }
+#line 1719 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 23:
+#line 248 "parser.y" /* yacc.c:1646 */
+ { (yyval.term) = make_binop(A_CONCAT, (yyvsp[-2].term), (yyvsp[0].term), &(yyloc)); }
+#line 1725 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 24:
+#line 250 "parser.y" /* yacc.c:1646 */
+ { (yyval.term) = (yyvsp[0].term); }
+#line 1731 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 25:
+#line 253 "parser.y" /* yacc.c:1646 */
+ { (yyval.term) = make_binop(A_APP, (yyvsp[-1].term), (yyvsp[0].term), &(yyloc)); }
+#line 1737 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 26:
+#line 255 "parser.y" /* yacc.c:1646 */
+ { (yyval.term) = (yyvsp[0].term); }
+#line 1743 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 27:
+#line 258 "parser.y" /* yacc.c:1646 */
+ { (yyval.term) = make_ident((yyvsp[0].string), &(yylsp[0])); }
+#line 1749 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 28:
+#line 260 "parser.y" /* yacc.c:1646 */
+ { (yyval.term) = make_string_term((yyvsp[0].string), &(yylsp[0])); }
+#line 1755 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 29:
+#line 262 "parser.y" /* yacc.c:1646 */
+ { (yyval.term) = make_regexp_term((yyvsp[0].regexp).pattern, (yyvsp[0].regexp).nocase, &(yylsp[0])); }
+#line 1761 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 30:
+#line 264 "parser.y" /* yacc.c:1646 */
+ { (yyval.term) = (yyvsp[-1].term); }
+#line 1767 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 31:
+#line 266 "parser.y" /* yacc.c:1646 */
+ { (yyval.term) = make_unop(A_BRACKET, (yyvsp[-1].term), &(yyloc)); }
+#line 1773 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 32:
+#line 268 "parser.y" /* yacc.c:1646 */
+ { (yyval.term) = make_unit_term(&(yyloc)); }
+#line 1779 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 33:
+#line 271 "parser.y" /* yacc.c:1646 */
+ { (yyval.term) = make_rep((yyvsp[-1].term), (yyvsp[0].quant), &(yyloc)); }
+#line 1785 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 34:
+#line 273 "parser.y" /* yacc.c:1646 */
+ { (yyval.term) = (yyvsp[0].term); }
+#line 1791 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 35:
+#line 276 "parser.y" /* yacc.c:1646 */
+ { (yyval.quant) = Q_STAR; }
+#line 1797 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 36:
+#line 278 "parser.y" /* yacc.c:1646 */
+ { (yyval.quant) = Q_PLUS; }
+#line 1803 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 37:
+#line 280 "parser.y" /* yacc.c:1646 */
+ { (yyval.quant) = Q_MAYBE; }
+#line 1809 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 38:
+#line 283 "parser.y" /* yacc.c:1646 */
+ { (yyval.string) = (yyvsp[0].string); }
+#line 1815 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 39:
+#line 285 "parser.y" /* yacc.c:1646 */
+ { (yyval.string) = (yyvsp[0].string); }
+#line 1821 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 40:
+#line 287 "parser.y" /* yacc.c:1646 */
+ { (yyval.string) = strdup("get"); }
+#line 1827 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 41:
+#line 289 "parser.y" /* yacc.c:1646 */
+ { (yyval.string) = strdup("put"); }
+#line 1833 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 42:
+#line 292 "parser.y" /* yacc.c:1646 */
+ { (yyval.term) = (yyvsp[0].term); list_cons((yyval.term), (yyvsp[-1].term)); }
+#line 1839 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 43:
+#line 294 "parser.y" /* yacc.c:1646 */
+ { (yyval.term) = NULL; }
+#line 1845 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 44:
+#line 297 "parser.y" /* yacc.c:1646 */
+ { (yyval.term) = make_param((yyvsp[-3].string), (yyvsp[-1].type), clone_info(&(yylsp[-4]))); }
+#line 1851 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 45:
+#line 300 "parser.y" /* yacc.c:1646 */
+ { (yyval.string) = (yyvsp[0].string); }
+#line 1857 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 46:
+#line 302 "parser.y" /* yacc.c:1646 */
+ { (yyval.string) = strdup("get"); }
+#line 1863 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 47:
+#line 304 "parser.y" /* yacc.c:1646 */
+ { (yyval.string) = strdup("put"); }
+#line 1869 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 48:
+#line 307 "parser.y" /* yacc.c:1646 */
+ { (yyval.type) = make_arrow_type((yyvsp[-2].type), (yyvsp[0].type)); }
+#line 1875 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 49:
+#line 309 "parser.y" /* yacc.c:1646 */
+ { (yyval.type) = (yyvsp[0].type); }
+#line 1881 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 50:
+#line 312 "parser.y" /* yacc.c:1646 */
+ { (yyval.type) = make_base_type(T_STRING); }
+#line 1887 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 51:
+#line 314 "parser.y" /* yacc.c:1646 */
+ { (yyval.type) = make_base_type(T_REGEXP); }
+#line 1893 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 52:
+#line 316 "parser.y" /* yacc.c:1646 */
+ { (yyval.type) = make_base_type(T_LENS); }
+#line 1899 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 53:
+#line 318 "parser.y" /* yacc.c:1646 */
+ { (yyval.type) = (yyvsp[-1].type); }
+#line 1905 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 54:
+#line 321 "parser.y" /* yacc.c:1646 */
+ { (yyval.tree) = tree_concat((yyvsp[-3].tree), (yyvsp[-1].tree)); }
+#line 1911 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 55:
+#line 323 "parser.y" /* yacc.c:1646 */
+ { (yyval.tree) = tree_concat((yyvsp[-1].tree), NULL); }
+#line 1917 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 56:
+#line 326 "parser.y" /* yacc.c:1646 */
+ {
+ (yyval.tree) = tree_concat((yyvsp[-3].tree), (yyvsp[-1].tree));
+ }
+#line 1925 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 57:
+#line 330 "parser.y" /* yacc.c:1646 */
+ { (yyval.tree) = NULL; }
+#line 1931 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 58:
+#line 333 "parser.y" /* yacc.c:1646 */
+ {
+ (yyval.tree) = make_tree((yyvsp[-1].string), NULL, NULL, (yyvsp[0].tree));
+ }
+#line 1939 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 59:
+#line 337 "parser.y" /* yacc.c:1646 */
+ {
+ (yyval.tree) = make_tree((yyvsp[-3].string), (yyvsp[-1].string), NULL, (yyvsp[0].tree));
+ }
+#line 1947 "parser.c" /* yacc.c:1646 */
+ break;
+
+ case 61:
+#line 342 "parser.y" /* yacc.c:1646 */
+ { (yyval.string) = NULL; }
+#line 1953 "parser.c" /* yacc.c:1646 */
+ break;
+
+
+#line 1957 "parser.c" /* yacc.c:1646 */
+ 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 ("-> $$ =", yyr1[yyn], &yyval, &yyloc);
+
+ YYPOPSTACK (yylen);
+ yylen = 0;
+ YY_STACK_PRINT (yyss, yyssp);
+
+ *++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. */
+
+ yyn = yyr1[yyn];
+
+ yystate = yypgoto[yyn - YYNTOKENS] + *yyssp;
+ if (0 <= yystate && yystate <= YYLAST && yycheck[yystate] == *yyssp)
+ yystate = yytable[yystate];
+ else
+ yystate = yydefgoto[yyn - YYNTOKENS];
+
+ 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 ? YYEMPTY : YYTRANSLATE (yychar);
+
+ /* If not already recovering from an error, report this error. */
+ if (!yyerrstatus)
+ {
+ ++yynerrs;
+#if ! YYERROR_VERBOSE
+ yyerror (&yylloc, term, scanner, YY_("syntax error"));
+#else
+# define YYSYNTAX_ERROR yysyntax_error (&yymsg_alloc, &yymsg, \
+ yyssp, yytoken)
+ {
+ char const *yymsgp = YY_("syntax error");
+ int yysyntax_error_status;
+ yysyntax_error_status = YYSYNTAX_ERROR;
+ if (yysyntax_error_status == 0)
+ yymsgp = yymsg;
+ else if (yysyntax_error_status == 1)
+ {
+ if (yymsg != yymsgbuf)
+ YYSTACK_FREE (yymsg);
+ yymsg = (char *) YYSTACK_ALLOC (yymsg_alloc);
+ if (!yymsg)
+ {
+ yymsg = yymsgbuf;
+ yymsg_alloc = sizeof yymsgbuf;
+ yysyntax_error_status = 2;
+ }
+ else
+ {
+ yysyntax_error_status = YYSYNTAX_ERROR;
+ yymsgp = yymsg;
+ }
+ }
+ yyerror (&yylloc, term, scanner, yymsgp);
+ if (yysyntax_error_status == 2)
+ goto yyexhaustedlab;
+ }
+# undef YYSYNTAX_ERROR
+#endif
+ }
+
+ 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, term, scanner);
+ 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 like GCC when the user code never invokes
+ YYERROR and the label yyerrorlab therefore never appears in user
+ code. */
+ if (/*CONSTCOND*/ 0)
+ goto yyerrorlab;
+
+ yyerror_range[1] = yylsp[1-yylen];
+ /* 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. */
+
+ for (;;)
+ {
+ yyn = yypact[yystate];
+ if (!yypact_value_is_default (yyn))
+ {
+ yyn += YYTERROR;
+ if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR)
+ {
+ 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",
+ yystos[yystate], yyvsp, yylsp, term, scanner);
+ 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;
+ /* Using YYLLOC is tempting, but would change the location of
+ the lookahead. YYLOC is available though. */
+ YYLLOC_DEFAULT (yyloc, yyerror_range, 2);
+ *++yylsp = yyloc;
+
+ /* Shift the error token. */
+ YY_SYMBOL_PRINT ("Shifting", yystos[yyn], yyvsp, yylsp);
+
+ yystate = yyn;
+ goto yynewstate;
+
+
+/*-------------------------------------.
+| yyacceptlab -- YYACCEPT comes here. |
+`-------------------------------------*/
+yyacceptlab:
+ yyresult = 0;
+ goto yyreturn;
+
+/*-----------------------------------.
+| yyabortlab -- YYABORT comes here. |
+`-----------------------------------*/
+yyabortlab:
+ yyresult = 1;
+ goto yyreturn;
+
+#if !defined yyoverflow || YYERROR_VERBOSE
+/*-------------------------------------------------.
+| yyexhaustedlab -- memory exhaustion comes here. |
+`-------------------------------------------------*/
+yyexhaustedlab:
+ yyerror (&yylloc, term, scanner, YY_("memory exhausted"));
+ yyresult = 2;
+ /* Fall through. */
+#endif
+
+yyreturn:
+ 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, term, scanner);
+ }
+ /* 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",
+ yystos[*yyssp], yyvsp, yylsp, term, scanner);
+ YYPOPSTACK (1);
+ }
+#ifndef yyoverflow
+ if (yyss != yyssa)
+ YYSTACK_FREE (yyss);
+#endif
+#if YYERROR_VERBOSE
+ if (yymsg != yymsgbuf)
+ YYSTACK_FREE (yymsg);
+#endif
+ return yyresult;
+}
+#line 343 "parser.y" /* yacc.c:1906 */
+
+
+int augl_parse_file(struct augeas *aug, const char *name,
+ struct term **term) {
+ yyscan_t scanner;
+ struct state state;
+ struct string *sname = NULL;
+ struct info info;
+ int result = -1;
+ int r;
+
+ *term = NULL;
+
+ r = make_ref(sname);
+ ERR_NOMEM(r < 0, aug);
+
+ sname->str = strdup(name);
+ ERR_NOMEM(sname->str == NULL, aug);
+
+ MEMZERO(&info, 1);
+ info.ref = UINT_MAX;
+ info.filename = sname;
+ info.error = aug->error;
+
+ MEMZERO(&state, 1);
+ state.info = &info;
+ state.comment_depth = 0;
+
+ if (augl_init_lexer(&state, &scanner) < 0) {
+ augl_error(&info, term, NULL, "file not found");
+ goto error;
+ }
+
+ yydebug = getenv("YYDEBUG") != NULL;
+ r = augl_parse(term, scanner);
+ augl_close_lexer(scanner);
+ augl_lex_destroy(scanner);
+ if (r == 1) {
+ augl_error(&info, term, NULL, "syntax error");
+ goto error;
+ } else if (r == 2) {
+ augl_error(&info, term, NULL, "parser ran out of memory");
+ ERR_NOMEM(1, aug);
+ }
+ result = 0;
+
+ error:
+ unref(sname, string);
+ // free TERM
+ return result;
+}
+
+// FIXME: Nothing here checks for alloc errors.
+static struct info *clone_info(struct info *locp) {
+ struct info *info;
+ make_ref(info);
+ info->filename = ref(locp->filename);
+ info->first_line = locp->first_line;
+ info->first_column = locp->first_column;
+ info->last_line = locp->last_line;
+ info->last_column = locp->last_column;
+ info->error = locp->error;
+ return info;
+}
+
+static struct term *make_term_locp(enum term_tag tag, struct info *locp) {
+ struct info *info = clone_info(locp);
+ return make_term(tag, info);
+}
+
+static struct term *make_module(char *ident, char *autoload,
+ struct term *decls,
+ struct info *locp) {
+ struct term *term = make_term_locp(A_MODULE, locp);
+ term->mname = ident;
+ term->autoload = autoload;
+ term->decls = decls;
+ return term;
+}
+
+static struct term *make_bind(char *ident, struct term *params,
+ struct term *exp, struct term *decls,
+ struct info *locp) {
+ struct term *term = make_term_locp(A_BIND, locp);
+ if (params != NULL)
+ exp = build_func(params, exp);
+
+ term->bname = ident;
+ term->exp = exp;
+ list_cons(decls, term);
+ return decls;
+}
+
+static struct term *make_bind_rec(char *ident, struct term *exp,
+ struct term *decls, struct info *locp) {
+ /* Desugar let rec IDENT = EXP as
+ * let IDENT =
+ * let RLENS = (lns_make_rec) in
+ * lns_check_rec ((lambda IDENT: EXP) RLENS) RLENS
+ * where RLENS is a brandnew recursive lens.
+ *
+ * That only works since we know that 'let rec' is only defined for lenses,
+ * not general purposes functions, i.e. we know that IDENT has type 'lens'
+ *
+ * The point of all this is that we make it possible to put a recursive
+ * lens (which is a placeholder for the actual recursion) into arbitrary
+ * places in some bigger lens and then have LNS_CHECK_REC rattle through
+ * to do the special-purpose typechecking.
+ */
+ char *id;
+ struct info *info = exp->info;
+ struct term *lambda = NULL, *rlens = NULL;
+ struct term *app1 = NULL, *app2 = NULL, *app3 = NULL;
+
+ id = strdup(ident);
+ if (id == NULL) goto error;
+
+ lambda = make_param(id, make_base_type(T_LENS), ref(info));
+ if (lambda == NULL) goto error;
+ id = NULL;
+
+ build_func(lambda, exp);
+
+ rlens = make_term(A_VALUE, ref(exp->info));
+ if (rlens == NULL) goto error;
+ rlens->value = lns_make_rec(ref(exp->info));
+ if (rlens->value == NULL) goto error;
+ rlens->type = make_base_type(T_LENS);
+
+ app1 = make_app_term(lambda, rlens, ref(info));
+ if (app1 == NULL) goto error;
+
+ id = strdup(LNS_CHECK_REC_NAME);
+ if (id == NULL) goto error;
+ app2 = make_app_ident(id, app1, ref(info));
+ if (app2 == NULL) goto error;
+ id = NULL;
+
+ app3 = make_app_term(app2, ref(rlens), ref(info));
+ if (app3 == NULL) goto error;
+
+ return make_bind(ident, NULL, app3, decls, locp);
+
+ error:
+ free(id);
+ unref(lambda, term);
+ unref(rlens, term);
+ unref(app1, term);
+ unref(app2, term);
+ unref(app3, term);
+ return NULL;
+}
+
+static struct term *make_let(char *ident, struct term *params,
+ struct term *exp, struct term *body,
+ struct info *locp) {
+ /* let f (x:string) = "f " . x in
+ f "a" . f "b" */
+ /* (lambda f: f "a" . f "b") (lambda x: "f " . x) */
+ /* (lambda IDENT: BODY) (lambda PARAMS: EXP) */
+ /* Desugar as (lambda IDENT: BODY) (lambda PARAMS: EXP) */
+ struct term *term = make_term_locp(A_LET, locp);
+ struct term *p = make_param(ident, NULL, ref(term->info));
+ term->left = build_func(p, body);
+ if (params != NULL)
+ term->right = build_func(params, exp);
+ else
+ term->right = exp;
+ return term;
+}
+
+static struct term *make_binop(enum term_tag tag,
+ struct term *left, struct term *right,
+ struct info *locp) {
+ assert(tag == A_COMPOSE || tag == A_CONCAT
+ || tag == A_UNION || tag == A_APP || tag == A_MINUS);
+ struct term *term = make_term_locp(tag, locp);
+ term->left = left;
+ term->right = right;
+ return term;
+}
+
+static struct term *make_unop(enum term_tag tag, struct term *exp,
+ struct info *locp) {
+ assert(tag == A_BRACKET);
+ struct term *term = make_term_locp(tag, locp);
+ term->brexp = exp;
+ return term;
+}
+
+static struct term *make_ident(char *qname, struct info *locp) {
+ struct term *term = make_term_locp(A_IDENT, locp);
+ term->ident = make_string(qname);
+ return term;
+}
+
+static struct term *make_unit_term(struct info *locp) {
+ struct term *term = make_term_locp(A_VALUE, locp);
+ term->value = make_unit(ref(term->info));
+ return term;
+}
+
+static struct term *make_string_term(char *value, struct info *locp) {
+ struct term *term = make_term_locp(A_VALUE, locp);
+ term->value = make_value(V_STRING, ref(term->info));
+ term->value->string = make_string(value);
+ return term;
+}
+
+static struct term *make_regexp_term(char *pattern, int nocase,
+ struct info *locp) {
+ struct term *term = make_term_locp(A_VALUE, locp);
+ term->value = make_value(V_REGEXP, ref(term->info));
+ term->value->regexp = make_regexp(term->info, pattern, nocase);
+ return term;
+}
+
+static struct term *make_rep(struct term *exp, enum quant_tag quant,
+ struct info *locp) {
+ struct term *term = make_term_locp(A_REP, locp);
+ term->quant = quant;
+ term->exp = exp;
+ return term;
+}
+
+static struct term *make_get_test(struct term *lens, struct term *arg,
+ struct info *locp) {
+ /* Return a term for "get" LENS ARG */
+ struct info *info = clone_info(locp);
+ struct term *term = make_app_ident(strdup("get"), lens, info);
+ term = make_app_term(term, arg, ref(info));
+ return term;
+}
+
+static struct term *make_put_test(struct term *lens, struct term *arg,
+ struct term *cmds, struct info *locp) {
+ /* Return a term for "put" LENS (CMDS ("get" LENS ARG)) ARG */
+ struct term *term = make_get_test(lens, arg, locp);
+ term = make_app_term(cmds, term, ref(term->info));
+ struct term *put = make_app_ident(strdup("put"), ref(lens), ref(term->info));
+ put = make_app_term(put, term, ref(term->info));
+ put = make_app_term(put, ref(arg), ref(term->info));
+ return put;
+}
+
+static struct term *make_test(struct term *test, struct term *result,
+ enum test_result_tag tr_tag,
+ struct term *decls, struct info *locp) {
+ struct term *term = make_term_locp(A_TEST, locp);
+ term->tr_tag = tr_tag;
+ term->test = test;
+ term->result = result;
+ term->next = decls;
+ return term;
+}
+
+static struct term *make_tree_value(struct tree *tree, struct info *locp) {
+ struct term *term = make_term_locp(A_VALUE, locp);
+ struct value *value = make_value(V_TREE, ref(term->info));
+ value->origin = make_tree_origin(tree);
+ term->value = value;
+ return term;
+}
+
+static struct tree *tree_concat(struct tree *t1, struct tree *t2) {
+ if (t2 != NULL)
+ list_append(t1, t2);
+ return t1;
+}
+
+void augl_error(struct info *locp,
+ struct term **term,
+ yyscan_t scanner,
+ const char *s) {
+ struct info info;
+ struct string string;
+ MEMZERO(&info, 1);
+ info.ref = string.ref = UINT_MAX;
+ info.filename = &string;
+
+ if (locp != NULL) {
+ info.first_line = locp->first_line;
+ info.first_column = locp->first_column;
+ info.last_line = locp->last_line;
+ info.last_column = locp->last_column;
+ info.filename->str = locp->filename->str;
+ info.error = locp->error;
+ } else if (scanner != NULL) {
+ info.first_line = augl_get_lineno(scanner);
+ info.first_column = augl_get_column(scanner);
+ info.last_line = augl_get_lineno(scanner);
+ info.last_column = augl_get_column(scanner);
+ info.filename = augl_get_info(scanner)->filename;
+ info.error = augl_get_info(scanner)->error;
+ } else if (*term != NULL && (*term)->info != NULL) {
+ memcpy(&info, (*term)->info, sizeof(info));
+ } else {
+ info.first_line = info.last_line = 0;
+ info.first_column = info.last_column = 0;
+ }
+ syntax_error(&info, "%s", s);
+}
diff --git a/libraries/cmake/source/augeas/generated/linux/aarch64/code/parser.h b/libraries/cmake/source/augeas/generated/linux/aarch64/code/parser.h
new file mode 100644
index 00000000000..da50b68b297
--- /dev/null
+++ b/libraries/cmake/source/augeas/generated/linux/aarch64/code/parser.h
@@ -0,0 +1,146 @@
+/* A Bison parser, made by GNU Bison 3.0.4. */
+
+/* Bison interface for Yacc-like parsers in C
+
+ Copyright (C) 1984, 1989-1990, 2000-2015 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. */
+
+#ifndef YY_AUGL_PARSER_H_INCLUDED
+# define YY_AUGL_PARSER_H_INCLUDED
+/* Debug traces. */
+#ifndef YYDEBUG
+# define YYDEBUG 0
+#endif
+#if YYDEBUG
+extern int augl_debug;
+#endif
+
+/* Token type. */
+#ifndef YYTOKENTYPE
+# define YYTOKENTYPE
+ enum yytokentype
+ {
+ DQUOTED = 258,
+ REGEXP = 259,
+ LIDENT = 260,
+ UIDENT = 261,
+ QIDENT = 262,
+ ARROW = 263,
+ KW_MODULE = 264,
+ KW_AUTOLOAD = 265,
+ KW_LET = 266,
+ KW_LET_REC = 267,
+ KW_IN = 268,
+ KW_STRING = 269,
+ KW_REGEXP = 270,
+ KW_LENS = 271,
+ KW_TEST = 272,
+ KW_GET = 273,
+ KW_PUT = 274,
+ KW_AFTER = 275
+ };
+#endif
+/* Tokens. */
+#define DQUOTED 258
+#define REGEXP 259
+#define LIDENT 260
+#define UIDENT 261
+#define QIDENT 262
+#define ARROW 263
+#define KW_MODULE 264
+#define KW_AUTOLOAD 265
+#define KW_LET 266
+#define KW_LET_REC 267
+#define KW_IN 268
+#define KW_STRING 269
+#define KW_REGEXP 270
+#define KW_LENS 271
+#define KW_TEST 272
+#define KW_GET 273
+#define KW_PUT 274
+#define KW_AFTER 275
+
+/* Value type. */
+#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
+
+union YYSTYPE
+{
+#line 89 "parser.y" /* yacc.c:1909 */
+
+ struct term *term;
+ struct type *type;
+ struct ident *ident;
+ struct tree *tree;
+ char *string;
+ struct {
+ int nocase;
+ char *pattern;
+ } regexp;
+ int intval;
+ enum quant_tag quant;
+
+#line 108 "parser.h" /* yacc.c:1909 */
+};
+
+typedef union YYSTYPE YYSTYPE;
+# define YYSTYPE_IS_TRIVIAL 1
+# define YYSTYPE_IS_DECLARED 1
+#endif
+
+/* 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 augl_parse (struct term **term, yyscan_t scanner);
+/* "%code provides" blocks. */
+#line 46 "parser.y" /* yacc.c:1909 */
+
+#include "info.h"
+
+/* Track custom scanner state */
+struct state {
+ struct info *info;
+ unsigned int comment_depth;
+};
+
+
+#line 145 "parser.h" /* yacc.c:1909 */
+
+#endif /* !YY_AUGL_PARSER_H_INCLUDED */
diff --git a/libraries/cmake/source/augeas/config/linux/config.h b/libraries/cmake/source/augeas/generated/linux/aarch64/config/config.h
similarity index 60%
rename from libraries/cmake/source/augeas/config/linux/config.h
rename to libraries/cmake/source/augeas/generated/linux/aarch64/config/config.h
index 67ffcfba730..725aea19cf7 100644
--- a/libraries/cmake/source/augeas/config/linux/config.h
+++ b/libraries/cmake/source/augeas/generated/linux/aarch64/config/config.h
@@ -43,6 +43,9 @@
/* whether debugging is enabled */
#define ENABLE_DEBUG 1
+/* Define this to 1 if F_DUPFD behavior does not match POSIX */
+/* #undef FCNTL_DUPFD_BUGGY */
+
/* Define to nothing if C supports flexible array members, and to 1 if it does
not. That way, with a declaration like 'struct s { int n; double
d[FLEXIBLE_ARRAY_MEMBER]; };', the struct hack can be used with pre-C99
@@ -59,6 +62,10 @@
#endif
+/* Define to 1 if mkdir mistakenly creates a directory given with a trailing
+ dot component. */
+/* #undef FUNC_MKDIR_DOT_BUG */
+
/* Define to 1 if nl_langinfo (YESEXPR) returns a non-empty string. */
#define FUNC_NL_LANGINFO_YESEXPR_WORKS 1
@@ -85,6 +92,10 @@
whether the gnulib module lock shall be considered present. */
#define GNULIB_LOCK 1
+/* Define to a C preprocessor expression that evaluates to 1 or 0, depending
+ whether the gnulib module msvc-nothrow shall be considered present. */
+#define GNULIB_MSVC_NOTHROW IN_AUGEAS_GNULIB_TESTS
+
/* Define to 1 if printf and friends should be labeled with attribute
"__gnu_printf__" instead of "__printf__" */
/* #undef GNULIB_PRINTF_ATTRIBUTE_FLAVOR_GNU */
@@ -93,6 +104,20 @@
whether the gnulib module scanf shall be considered present. */
#define GNULIB_SCANF 1
+/* Define to a C preprocessor expression that evaluates to 1 or 0, depending
+ whether the gnulib module strerror shall be considered present. */
+#define GNULIB_STRERROR IN_AUGEAS_GNULIB_TESTS
+
+/* Define to a C preprocessor expression that evaluates to 1 or 0, depending
+ whether the gnulib module strerror_r-posix shall be considered present. */
+#define GNULIB_STRERROR_R_POSIX IN_AUGEAS_GNULIB_TESTS
+
+/* Define to 1 when the gnulib module accept should be tested. */
+#define GNULIB_TEST_ACCEPT 1
+
+/* Define to 1 when the gnulib module bind should be tested. */
+#define GNULIB_TEST_BIND 1
+
/* Define to 1 when the gnulib module btowc should be tested. */
#define GNULIB_TEST_BTOWC 1
@@ -100,21 +125,36 @@
*/
#define GNULIB_TEST_CANONICALIZE_FILE_NAME 1
+/* Define to 1 when the gnulib module cloexec should be tested. */
+#define GNULIB_TEST_CLOEXEC 1
+
/* Define to 1 when the gnulib module close should be tested. */
#define GNULIB_TEST_CLOSE 1
+/* Define to 1 when the gnulib module connect should be tested. */
+#define GNULIB_TEST_CONNECT 1
+
/* Define to 1 when the gnulib module dup2 should be tested. */
#define GNULIB_TEST_DUP2 1
/* Define to 1 when the gnulib module environ should be tested. */
#define GNULIB_TEST_ENVIRON 1
+/* Define to 1 when the gnulib module fcntl should be tested. */
+#define GNULIB_TEST_FCNTL 1
+
/* Define to 1 when the gnulib module fdopen should be tested. */
#define GNULIB_TEST_FDOPEN 1
+/* Define to 1 when the gnulib module fnmatch should be tested. */
+#define GNULIB_TEST_FNMATCH 1
+
/* Define to 1 when the gnulib module fstat should be tested. */
#define GNULIB_TEST_FSTAT 1
+/* Define to 1 when the gnulib module ftruncate should be tested. */
+#define GNULIB_TEST_FTRUNCATE 1
+
/* Define to 1 when the gnulib module getcwd should be tested. */
#define GNULIB_TEST_GETCWD 1
@@ -133,9 +173,18 @@
/* Define to 1 when the gnulib module gettimeofday should be tested. */
#define GNULIB_TEST_GETTIMEOFDAY 1
+/* Define to 1 when the gnulib module ioctl should be tested. */
+#define GNULIB_TEST_IOCTL 1
+
+/* Define to 1 when the gnulib module listen should be tested. */
+#define GNULIB_TEST_LISTEN 1
+
/* Define to 1 when the gnulib module localeconv should be tested. */
#define GNULIB_TEST_LOCALECONV 1
+/* Define to 1 when the gnulib module localename should be tested. */
+#define GNULIB_TEST_LOCALENAME 1
+
/* Define to 1 when the gnulib module lstat should be tested. */
#define GNULIB_TEST_LSTAT 1
@@ -163,15 +212,30 @@
/* Define to 1 when the gnulib module mkstemp should be tested. */
#define GNULIB_TEST_MKSTEMP 1
+/* Define to 1 when the gnulib module nanosleep should be tested. */
+#define GNULIB_TEST_NANOSLEEP 1
+
/* Define to 1 when the gnulib module nl_langinfo should be tested. */
#define GNULIB_TEST_NL_LANGINFO 1
/* Define to 1 when the gnulib module open should be tested. */
#define GNULIB_TEST_OPEN 1
+/* Define to 1 when the gnulib module perror should be tested. */
+#define GNULIB_TEST_PERROR 1
+
+/* Define to 1 when the gnulib module pipe should be tested. */
+#define GNULIB_TEST_PIPE 1
+
+/* Define to 1 when the gnulib module pthread_sigmask should be tested. */
+#define GNULIB_TEST_PTHREAD_SIGMASK 1
+
/* Define to 1 when the gnulib module putenv should be tested. */
#define GNULIB_TEST_PUTENV 1
+/* Define to 1 when the gnulib module raise should be tested. */
+#define GNULIB_TEST_RAISE 1
+
/* Define to 1 when the gnulib module rawmemchr should be tested. */
#define GNULIB_TEST_RAWMEMCHR 1
@@ -181,8 +245,8 @@
/* Define to 1 when the gnulib module realpath should be tested. */
#define GNULIB_TEST_REALPATH 1
-/* Define to 1 when the gnulib module secure_getenv should be tested. */
-#define GNULIB_TEST_SECURE_GETENV 1
+/* Define to 1 when the gnulib module select should be tested. */
+#define GNULIB_TEST_SELECT 1
/* Define to 1 when the gnulib module setenv should be tested. */
#define GNULIB_TEST_SETENV 1
@@ -190,9 +254,21 @@
/* Define to 1 when the gnulib module setlocale should be tested. */
#define GNULIB_TEST_SETLOCALE 1
+/* Define to 1 when the gnulib module setsockopt should be tested. */
+#define GNULIB_TEST_SETSOCKOPT 1
+
+/* Define to 1 when the gnulib module sigaction should be tested. */
+#define GNULIB_TEST_SIGACTION 1
+
+/* Define to 1 when the gnulib module sigprocmask should be tested. */
+#define GNULIB_TEST_SIGPROCMASK 1
+
/* Define to 1 when the gnulib module sleep should be tested. */
#define GNULIB_TEST_SLEEP 1
+/* Define to 1 when the gnulib module socket should be tested. */
+#define GNULIB_TEST_SOCKET 1
+
/* Define to 1 when the gnulib module stat should be tested. */
#define GNULIB_TEST_STAT 1
@@ -205,6 +281,12 @@
/* Define to 1 when the gnulib module strchrnul should be tested. */
#define GNULIB_TEST_STRCHRNUL 1
+/* Define to 1 when the gnulib module strerror should be tested. */
+#define GNULIB_TEST_STRERROR 1
+
+/* Define to 1 when the gnulib module strerror_r should be tested. */
+#define GNULIB_TEST_STRERROR_R 1
+
/* Define to 1 when the gnulib module strndup should be tested. */
#define GNULIB_TEST_STRNDUP 1
@@ -246,30 +328,49 @@
/* Define to 1 if you have the header file. */
#define HAVE_ARGZ_H 1
+/* Define to 1 if you have the header file. */
+#define HAVE_ARPA_INET_H 1
+
/* Define to 1 if you have the header file. */
/* #undef HAVE_BP_SYM_H */
-/* Define to 1 if you have the 'btowc' function. */
+/* Define to 1 if you have the `btowc' function. */
#define HAVE_BTOWC 1
-/* Define to 1 if you have the 'canonicalize_file_name' function. */
+/* Define to 1 if nanosleep mishandles large arguments. */
+#define HAVE_BUG_BIG_NANOSLEEP 1
+
+/* Define to 1 if you have the `canonicalize_file_name' function. */
#define HAVE_CANONICALIZE_FILE_NAME 1
+/* Define to 1 if you have the `catgets' function. */
+#define HAVE_CATGETS 1
+
/* Define to 1 if you have the Mac OS X function CFLocaleCopyCurrent in the
CoreFoundation framework. */
/* #undef HAVE_CFLOCALECOPYCURRENT */
+/* Define to 1 if you have the Mac OS X function
+ CFLocaleCopyPreferredLanguages in the CoreFoundation framework. */
+/* #undef HAVE_CFLOCALECOPYPREFERREDLANGUAGES */
+
/* Define to 1 if you have the Mac OS X function CFPreferencesCopyAppValue in
the CoreFoundation framework. */
/* #undef HAVE_CFPREFERENCESCOPYAPPVALUE */
+/* Define to 1 if you have the `chsize' function. */
+/* #undef HAVE_CHSIZE */
+
+/* Define to 1 if you have the header file. */
+/* #undef HAVE_CRTDEFS_H */
+
/* Define to 1 if you have the declaration of `alarm', and to 0 if you don't.
*/
#define HAVE_DECL_ALARM 1
/* Define to 1 if you have the declaration of `getc_unlocked', and to 0 if you
don't. */
-#define HAVE_DECL_GETC_UNLOCKED 1
+/* #undef HAVE_DECL_GETC_UNLOCKED */
/* Define to 1 if you have the declaration of `getdelim', and to 0 if you
don't. */
@@ -279,17 +380,17 @@
don't. */
#define HAVE_DECL_GETDTABLESIZE 1
-/* Define to 1 if you have the declaration of `getenv', and to 0 if you don't.
- */
-#define HAVE_DECL_GETENV 1
-
/* Define to 1 if you have the declaration of `getline', and to 0 if you
don't. */
#define HAVE_DECL_GETLINE 1
+/* Define to 1 if you have the declaration of `inet_pton', and to 0 if you
+ don't. */
+#define HAVE_DECL_INET_PTON 1
+
/* Define to 1 if you have the declaration of `isblank', and to 0 if you
don't. */
-/* #undef HAVE_DECL_ISBLANK */
+#define HAVE_DECL_ISBLANK 1
/* Define to 1 if you have the declaration of `mbrtowc', and to 0 if you
don't. */
@@ -315,6 +416,10 @@
don't. */
#define HAVE_DECL_STPNCPY 1
+/* Define to 1 if you have the declaration of `strerror_r', and to 0 if you
+ don't. */
+#define HAVE_DECL_STRERROR_R 1
+
/* Define to 1 if you have the declaration of `strndup', and to 0 if you
don't. */
#define HAVE_DECL_STRNDUP 1
@@ -353,42 +458,55 @@
/* Define to 1 if you have the 'dup2' function. */
#define HAVE_DUP2 1
+/* Define to 1 if you have the `duplocale' function. */
+#define HAVE_DUPLOCALE 1
+
/* Define if you have the declaration of environ. */
#define HAVE_ENVIRON_DECL 1
/* Define to 1 if the system has the type `error_t'. */
#define HAVE_ERROR_T 1
+/* Define if the locale_t type contains insufficient information, as on
+ OpenBSD. */
+/* #undef HAVE_FAKE_LOCALES */
+
+/* Define to 1 if you have the `fcntl' function. */
+#define HAVE_FCNTL 1
+
/* Define to 1 if you have the header file. */
#define HAVE_FEATURES_H 1
/* Define to 1 if you have the `flockfile' function. */
/* #undef HAVE_FLOCKFILE */
+/* Define to 1 if you have the `fnmatch' function. */
+#define HAVE_FNMATCH 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_FNMATCH_H 1
+
+/* Define to 1 if you have the `freelocale' function. */
+#define HAVE_FREELOCALE 1
+
/* Define to 1 if you have the `fsync' function. */
#define HAVE_FSYNC 1
+/* Define to 1 if you have the `ftruncate' function. */
+#define HAVE_FTRUNCATE 1
+
/* Define to 1 if you have the `funlockfile' function. */
/* #undef HAVE_FUNLOCKFILE */
-/* Define to 1 if you have the 'getcwd' function. */
+/* Define to 1 if you have the `getcwd' function. */
#define HAVE_GETCWD 1
-/* Define to 1 if you have the 'getdelim' function. */
+/* Define to 1 if you have the `getdelim' function. */
#define HAVE_GETDELIM 1
-/* Define to 1 if you have the 'getdtablesize' function. */
+/* Define to 1 if you have the `getdtablesize' function. */
#define HAVE_GETDTABLESIZE 1
-/* Define to 1 if you have the 'getegid' function. */
-#define HAVE_GETEGID 1
-
-/* Define to 1 if you have the 'geteuid' function. */
-#define HAVE_GETEUID 1
-
-/* Define to 1 if you have the 'getgid' function. */
-#define HAVE_GETGID 1
-
/* Define to 1 if you have the `getlocalename_l' function. */
/* #undef HAVE_GETLOCALENAME_L */
@@ -398,14 +516,11 @@
/* Define to 1 if you have the `getopt_long_only' function. */
#define HAVE_GETOPT_LONG_ONLY 1
-/* Define to 1 if you have the `getpagesize' function. */
-#define HAVE_GETPAGESIZE 1
-
-/* Define to 1 if you have the 'gettimeofday' function. */
+/* Define to 1 if you have the `gettimeofday' function. */
#define HAVE_GETTIMEOFDAY 1
-/* Define to 1 if you have the 'getuid' function. */
-#define HAVE_GETUID 1
+/* Define to 1 if you have the `inet_pton' function. */
+/* #undef HAVE_INET_PTON */
/* Define if you have the 'intmax_t' type in or . */
#define HAVE_INTMAX_T 1
@@ -417,16 +532,22 @@
declares uintmax_t. */
#define HAVE_INTTYPES_H_WITH_UINTMAX 1
-/* Define to 1 if you have the 'isblank' function. */
-#define HAVE_ISBLANK 1
+/* Define to 1 if you have the `ioctl' function. */
+#define HAVE_IOCTL 1
+
+/* Define to 1 if defines AF_INET. */
+#define HAVE_IPV4 1
-/* Define to 1 if you have the `issetugid' function. */
-/* #undef HAVE_ISSETUGID */
+/* Define to 1 if defines AF_INET6. */
+#define HAVE_IPV6 1
+
+/* Define to 1 if you have the `isblank' function. */
+#define HAVE_ISBLANK 1
-/* Define to 1 if you have the 'iswcntrl' function. */
+/* Define to 1 if you have the `iswcntrl' function. */
#define HAVE_ISWCNTRL 1
-/* Define to 1 if you have the 'iswctype' function. */
+/* Define to 1 if you have the `iswctype' function. */
#define HAVE_ISWCTYPE 1
/* Define if you have and nl_langinfo(CODESET). */
@@ -439,7 +560,7 @@
#define HAVE_LC_MESSAGES 1
/* Define to 1 if you have the header file. */
-/* #undef HAVE_LIBINTL_H */
+#define HAVE_LIBINTL_H 1
/* Define to 1 if you have the header file. */
#define HAVE_LIMITS_H 1
@@ -447,7 +568,7 @@
/* Define to 1 if the system has the type 'long long int'. */
#define HAVE_LONG_LONG_INT 1
-/* Define to 1 if you have the 'lstat' function. */
+/* Define to 1 if you have the `lstat' function. */
#define HAVE_LSTAT 1
/* Define to 1 if you have the header file. */
@@ -463,35 +584,48 @@
/* Define to 1 if you have the `mbrtowc' function. */
#define HAVE_MBRTOWC 1
-/* Define to 1 if you have the 'mbsinit' function. */
+/* Define to 1 if you have the `mbsinit' function. */
#define HAVE_MBSINIT 1
-/* Define to 1 if you have the 'mbsrtowcs' function. */
+/* Define to 1 if you have the `mbsrtowcs' function. */
#define HAVE_MBSRTOWCS 1
/* Define to 1 if declares mbstate_t. */
#define HAVE_MBSTATE_T 1
+/* Define to 1 if you have the `mbtowc' function. */
+#define HAVE_MBTOWC 1
+
/* Define to 1 if you have the header file. */
#define HAVE_MEMORY_H 1
/* Define to 1 if you have the `mempcpy' function. */
#define HAVE_MEMPCPY 1
-/* Define to 1 if you have the 'mkstemp' function. */
+/* Define to 1 if you have the `mkstemp' function. */
#define HAVE_MKSTEMP 1
-/* Define to 1 if you have the 'mprotect' function. */
+/* Define to 1 if you have the `mprotect' function. */
#define HAVE_MPROTECT 1
/* Define to 1 on MSVC platforms that have the "invalid parameter handler"
concept. */
/* #undef HAVE_MSVC_INVALID_PARAMETER_HANDLER */
-/* Define to 1 if you have the 'newlocale' function. */
+/* Define if the locale_t type does not contain the name of each locale
+ category. */
+/* #undef HAVE_NAMELESS_LOCALES */
+
+/* Define to 1 if you have the header file. */
+#define HAVE_NETDB_H 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_NETINET_IN_H 1
+
+/* Define to 1 if you have the `newlocale' function. */
#define HAVE_NEWLOCALE 1
-/* Define to 1 if you have the 'nl_langinfo' function. */
+/* Define to 1 if you have the `nl_langinfo' function. */
#define HAVE_NL_LANGINFO 1
/* Define to 1 if you have the `open_memstream' function. */
@@ -500,6 +634,9 @@
/* Define to 1 if you have the header file. */
/* #undef HAVE_OS_H */
+/* Define to 1 if you have the `pipe' function. */
+#define HAVE_PIPE 1
+
/* Define to 1 if you have the `pthread_atfork' function. */
#define HAVE_PTHREAD_ATFORK 1
@@ -513,576 +650,32 @@
reader. */
/* #undef HAVE_PTHREAD_RWLOCK_RDLOCK_PREFER_WRITER */
-/* Define to 1 if you have the `rawmemchr' function. */
-#define HAVE_RAWMEMCHR 1
-
-/* Define to 1 if atoll is declared even after undefining macros. */
-#define HAVE_RAW_DECL_ATOLL 1
-
-/* Define to 1 if btowc is declared even after undefining macros. */
-#define HAVE_RAW_DECL_BTOWC 1
-
-/* Define to 1 if canonicalize_file_name is declared even after undefining
- macros. */
-#define HAVE_RAW_DECL_CANONICALIZE_FILE_NAME 1
-
-/* Define to 1 if chdir is declared even after undefining macros. */
-#define HAVE_RAW_DECL_CHDIR 1
-
-/* Define to 1 if chown is declared even after undefining macros. */
-#define HAVE_RAW_DECL_CHOWN 1
-
-/* Define to 1 if dprintf is declared even after undefining macros. */
-#define HAVE_RAW_DECL_DPRINTF 1
-
-/* Define to 1 if dup is declared even after undefining macros. */
-#define HAVE_RAW_DECL_DUP 1
-
-/* Define to 1 if dup2 is declared even after undefining macros. */
-#define HAVE_RAW_DECL_DUP2 1
-
-/* Define to 1 if dup3 is declared even after undefining macros. */
-#define HAVE_RAW_DECL_DUP3 1
-
-/* Define to 1 if duplocale is declared even after undefining macros. */
-#define HAVE_RAW_DECL_DUPLOCALE 1
-
-/* Define to 1 if endusershell is declared even after undefining macros. */
-#define HAVE_RAW_DECL_ENDUSERSHELL 1
-
-/* Define to 1 if environ is declared even after undefining macros. */
-#define HAVE_RAW_DECL_ENVIRON 1
-
-/* Define to 1 if euidaccess is declared even after undefining macros. */
-#define HAVE_RAW_DECL_EUIDACCESS 1
-
-/* Define to 1 if faccessat is declared even after undefining macros. */
-#define HAVE_RAW_DECL_FACCESSAT 1
-
-/* Define to 1 if fchdir is declared even after undefining macros. */
-#define HAVE_RAW_DECL_FCHDIR 1
-
-/* Define to 1 if fchmodat is declared even after undefining macros. */
-#define HAVE_RAW_DECL_FCHMODAT 1
-
-/* Define to 1 if fchownat is declared even after undefining macros. */
-#define HAVE_RAW_DECL_FCHOWNAT 1
-
-/* Define to 1 if fcntl is declared even after undefining macros. */
-#define HAVE_RAW_DECL_FCNTL 1
-
-/* Define to 1 if fdatasync is declared even after undefining macros. */
-#define HAVE_RAW_DECL_FDATASYNC 1
-
-/* Define to 1 if ffsl is declared even after undefining macros. */
-#define HAVE_RAW_DECL_FFSL 1
-
-/* Define to 1 if ffsll is declared even after undefining macros. */
-#define HAVE_RAW_DECL_FFSLL 1
-
-/* Define to 1 if fpurge is declared even after undefining macros. */
-/* #undef HAVE_RAW_DECL_FPURGE */
-
-/* Define to 1 if fseeko is declared even after undefining macros. */
-#define HAVE_RAW_DECL_FSEEKO 1
-
-/* Define to 1 if fstat is declared even after undefining macros. */
-#define HAVE_RAW_DECL_FSTAT 1
-
-/* Define to 1 if fstatat is declared even after undefining macros. */
-#define HAVE_RAW_DECL_FSTATAT 1
-
-/* Define to 1 if fsync is declared even after undefining macros. */
-#define HAVE_RAW_DECL_FSYNC 1
-
-/* Define to 1 if ftello is declared even after undefining macros. */
-#define HAVE_RAW_DECL_FTELLO 1
-
-/* Define to 1 if ftruncate is declared even after undefining macros. */
-#define HAVE_RAW_DECL_FTRUNCATE 1
-
-/* Define to 1 if futimens is declared even after undefining macros. */
-#define HAVE_RAW_DECL_FUTIMENS 1
-
-/* Define to 1 if getcwd is declared even after undefining macros. */
-#define HAVE_RAW_DECL_GETCWD 1
-
-/* Define to 1 if getdelim is declared even after undefining macros. */
-#define HAVE_RAW_DECL_GETDELIM 1
-
-/* Define to 1 if getdomainname is declared even after undefining macros. */
-#define HAVE_RAW_DECL_GETDOMAINNAME 1
-
-/* Define to 1 if getdtablesize is declared even after undefining macros. */
-#define HAVE_RAW_DECL_GETDTABLESIZE 1
-
-/* Define to 1 if getgroups is declared even after undefining macros. */
-#define HAVE_RAW_DECL_GETGROUPS 1
-
-/* Define to 1 if gethostname is declared even after undefining macros. */
-#define HAVE_RAW_DECL_GETHOSTNAME 1
-
-/* Define to 1 if getline is declared even after undefining macros. */
-#define HAVE_RAW_DECL_GETLINE 1
-
-/* Define to 1 if getloadavg is declared even after undefining macros. */
-#define HAVE_RAW_DECL_GETLOADAVG 1
-
-/* Define to 1 if getlogin is declared even after undefining macros. */
-#define HAVE_RAW_DECL_GETLOGIN 1
-
-/* Define to 1 if getlogin_r is declared even after undefining macros. */
-#define HAVE_RAW_DECL_GETLOGIN_R 1
-
-/* Define to 1 if getpagesize is declared even after undefining macros. */
-#define HAVE_RAW_DECL_GETPAGESIZE 1
-
-/* Define to 1 if gets is declared even after undefining macros. */
-/* #undef HAVE_RAW_DECL_GETS */
-
-/* Define to 1 if getsubopt is declared even after undefining macros. */
-#define HAVE_RAW_DECL_GETSUBOPT 1
-
-/* Define to 1 if gettimeofday is declared even after undefining macros. */
-#define HAVE_RAW_DECL_GETTIMEOFDAY 1
-
-/* Define to 1 if getusershell is declared even after undefining macros. */
-#define HAVE_RAW_DECL_GETUSERSHELL 1
-
-/* Define to 1 if grantpt is declared even after undefining macros. */
-#define HAVE_RAW_DECL_GRANTPT 1
-
-/* Define to 1 if group_member is declared even after undefining macros. */
-#define HAVE_RAW_DECL_GROUP_MEMBER 1
-
-/* Define to 1 if imaxabs is declared even after undefining macros. */
-#define HAVE_RAW_DECL_IMAXABS 1
-
-/* Define to 1 if imaxdiv is declared even after undefining macros. */
-#define HAVE_RAW_DECL_IMAXDIV 1
-
-/* Define to 1 if initstate is declared even after undefining macros. */
-#define HAVE_RAW_DECL_INITSTATE 1
-
-/* Define to 1 if initstate_r is declared even after undefining macros. */
-#define HAVE_RAW_DECL_INITSTATE_R 1
-
-/* Define to 1 if isatty is declared even after undefining macros. */
-#define HAVE_RAW_DECL_ISATTY 1
-
-/* Define to 1 if isblank is declared even after undefining macros. */
-#define HAVE_RAW_DECL_ISBLANK 1
-
-/* Define to 1 if iswctype is declared even after undefining macros. */
-#define HAVE_RAW_DECL_ISWCTYPE 1
-
-/* Define to 1 if lchmod is declared even after undefining macros. */
-#define HAVE_RAW_DECL_LCHMOD 1
-
-/* Define to 1 if lchown is declared even after undefining macros. */
-#define HAVE_RAW_DECL_LCHOWN 1
-
-/* Define to 1 if link is declared even after undefining macros. */
-#define HAVE_RAW_DECL_LINK 1
-
-/* Define to 1 if linkat is declared even after undefining macros. */
-#define HAVE_RAW_DECL_LINKAT 1
-
-/* Define to 1 if lseek is declared even after undefining macros. */
-#define HAVE_RAW_DECL_LSEEK 1
-
-/* Define to 1 if lstat is declared even after undefining macros. */
-#define HAVE_RAW_DECL_LSTAT 1
-
-/* Define to 1 if mbrlen is declared even after undefining macros. */
-#define HAVE_RAW_DECL_MBRLEN 1
-
-/* Define to 1 if mbrtowc is declared even after undefining macros. */
-#define HAVE_RAW_DECL_MBRTOWC 1
-
-/* Define to 1 if mbsinit is declared even after undefining macros. */
-#define HAVE_RAW_DECL_MBSINIT 1
-
-/* Define to 1 if mbsnrtowcs is declared even after undefining macros. */
-#define HAVE_RAW_DECL_MBSNRTOWCS 1
-
-/* Define to 1 if mbsrtowcs is declared even after undefining macros. */
-#define HAVE_RAW_DECL_MBSRTOWCS 1
-
-/* Define to 1 if memmem is declared even after undefining macros. */
-#define HAVE_RAW_DECL_MEMMEM 1
-
-/* Define to 1 if mempcpy is declared even after undefining macros. */
-#define HAVE_RAW_DECL_MEMPCPY 1
-
-/* Define to 1 if memrchr is declared even after undefining macros. */
-#define HAVE_RAW_DECL_MEMRCHR 1
-
-/* Define to 1 if mkdirat is declared even after undefining macros. */
-#define HAVE_RAW_DECL_MKDIRAT 1
-
-/* Define to 1 if mkdtemp is declared even after undefining macros. */
-#define HAVE_RAW_DECL_MKDTEMP 1
-
-/* Define to 1 if mkfifo is declared even after undefining macros. */
-#define HAVE_RAW_DECL_MKFIFO 1
-
-/* Define to 1 if mkfifoat is declared even after undefining macros. */
-#define HAVE_RAW_DECL_MKFIFOAT 1
-
-/* Define to 1 if mknod is declared even after undefining macros. */
-#define HAVE_RAW_DECL_MKNOD 1
-
-/* Define to 1 if mknodat is declared even after undefining macros. */
-#define HAVE_RAW_DECL_MKNODAT 1
-
-/* Define to 1 if mkostemp is declared even after undefining macros. */
-#define HAVE_RAW_DECL_MKOSTEMP 1
-
-/* Define to 1 if mkostemps is declared even after undefining macros. */
-#define HAVE_RAW_DECL_MKOSTEMPS 1
-
-/* Define to 1 if mkstemp is declared even after undefining macros. */
-#define HAVE_RAW_DECL_MKSTEMP 1
-
-/* Define to 1 if mkstemps is declared even after undefining macros. */
-#define HAVE_RAW_DECL_MKSTEMPS 1
-
-/* Define to 1 if nl_langinfo is declared even after undefining macros. */
-#define HAVE_RAW_DECL_NL_LANGINFO 1
-
-/* Define to 1 if openat is declared even after undefining macros. */
-#define HAVE_RAW_DECL_OPENAT 1
-
-/* Define to 1 if pclose is declared even after undefining macros. */
-#define HAVE_RAW_DECL_PCLOSE 1
-
-/* Define to 1 if pipe is declared even after undefining macros. */
-#define HAVE_RAW_DECL_PIPE 1
-
-/* Define to 1 if pipe2 is declared even after undefining macros. */
-#define HAVE_RAW_DECL_PIPE2 1
-
-/* Define to 1 if popen is declared even after undefining macros. */
-#define HAVE_RAW_DECL_POPEN 1
-
-/* Define to 1 if posix_openpt is declared even after undefining macros. */
-#define HAVE_RAW_DECL_POSIX_OPENPT 1
-
-/* Define to 1 if pread is declared even after undefining macros. */
-#define HAVE_RAW_DECL_PREAD 1
+/* Define to 1 if the pthread_sigmask function can be used (despite bugs). */
+/* #undef HAVE_PTHREAD_SIGMASK */
-/* Define to 1 if ptsname is declared even after undefining macros. */
-#define HAVE_RAW_DECL_PTSNAME 1
+/* Define to 1 if you have the `raise' function. */
+#define HAVE_RAISE 1
-/* Define to 1 if ptsname_r is declared even after undefining macros. */
-#define HAVE_RAW_DECL_PTSNAME_R 1
-
-/* Define to 1 if pwrite is declared even after undefining macros. */
-#define HAVE_RAW_DECL_PWRITE 1
-
-/* Define to 1 if qsort_r is declared even after undefining macros. */
-#define HAVE_RAW_DECL_QSORT_R 1
-
-/* Define to 1 if random is declared even after undefining macros. */
-#define HAVE_RAW_DECL_RANDOM 1
-
-/* Define to 1 if random_r is declared even after undefining macros. */
-#define HAVE_RAW_DECL_RANDOM_R 1
-
-/* Define to 1 if rawmemchr is declared even after undefining macros. */
-#define HAVE_RAW_DECL_RAWMEMCHR 1
-
-/* Define to 1 if readlink is declared even after undefining macros. */
-#define HAVE_RAW_DECL_READLINK 1
-
-/* Define to 1 if readlinkat is declared even after undefining macros. */
-#define HAVE_RAW_DECL_READLINKAT 1
-
-/* Define to 1 if realpath is declared even after undefining macros. */
-#define HAVE_RAW_DECL_REALPATH 1
-
-/* Define to 1 if renameat is declared even after undefining macros. */
-#define HAVE_RAW_DECL_RENAMEAT 1
-
-/* Define to 1 if rmdir is declared even after undefining macros. */
-#define HAVE_RAW_DECL_RMDIR 1
-
-/* Define to 1 if rpmatch is declared even after undefining macros. */
-#define HAVE_RAW_DECL_RPMATCH 1
-
-/* Define to 1 if secure_getenv is declared even after undefining macros. */
-#define HAVE_RAW_DECL_SECURE_GETENV 1
-
-/* Define to 1 if setenv is declared even after undefining macros. */
-#define HAVE_RAW_DECL_SETENV 1
-
-/* Define to 1 if sethostname is declared even after undefining macros. */
-#define HAVE_RAW_DECL_SETHOSTNAME 1
-
-/* Define to 1 if setlocale is declared even after undefining macros. */
-#define HAVE_RAW_DECL_SETLOCALE 1
-
-/* Define to 1 if setstate is declared even after undefining macros. */
-#define HAVE_RAW_DECL_SETSTATE 1
-
-/* Define to 1 if setstate_r is declared even after undefining macros. */
-#define HAVE_RAW_DECL_SETSTATE_R 1
-
-/* Define to 1 if setusershell is declared even after undefining macros. */
-#define HAVE_RAW_DECL_SETUSERSHELL 1
-
-/* Define to 1 if sleep is declared even after undefining macros. */
-#define HAVE_RAW_DECL_SLEEP 1
-
-/* Define to 1 if snprintf is declared even after undefining macros. */
-#define HAVE_RAW_DECL_SNPRINTF 1
-
-/* Define to 1 if srandom is declared even after undefining macros. */
-#define HAVE_RAW_DECL_SRANDOM 1
-
-/* Define to 1 if srandom_r is declared even after undefining macros. */
-#define HAVE_RAW_DECL_SRANDOM_R 1
-
-/* Define to 1 if stat is declared even after undefining macros. */
-#define HAVE_RAW_DECL_STAT 1
-
-/* Define to 1 if stpcpy is declared even after undefining macros. */
-#define HAVE_RAW_DECL_STPCPY 1
-
-/* Define to 1 if stpncpy is declared even after undefining macros. */
-#define HAVE_RAW_DECL_STPNCPY 1
-
-/* Define to 1 if strcasestr is declared even after undefining macros. */
-#define HAVE_RAW_DECL_STRCASESTR 1
-
-/* Define to 1 if strchrnul is declared even after undefining macros. */
-#define HAVE_RAW_DECL_STRCHRNUL 1
-
-/* Define to 1 if strdup is declared even after undefining macros. */
-#define HAVE_RAW_DECL_STRDUP 1
-
-/* Define to 1 if strerror_r is declared even after undefining macros. */
-#define HAVE_RAW_DECL_STRERROR_R 1
-
-/* Define to 1 if strncat is declared even after undefining macros. */
-#define HAVE_RAW_DECL_STRNCAT 1
-
-/* Define to 1 if strndup is declared even after undefining macros. */
-#define HAVE_RAW_DECL_STRNDUP 1
-
-/* Define to 1 if strnlen is declared even after undefining macros. */
-#define HAVE_RAW_DECL_STRNLEN 1
-
-/* Define to 1 if strpbrk is declared even after undefining macros. */
-#define HAVE_RAW_DECL_STRPBRK 1
-
-/* Define to 1 if strsep is declared even after undefining macros. */
-#define HAVE_RAW_DECL_STRSEP 1
-
-/* Define to 1 if strsignal is declared even after undefining macros. */
-#define HAVE_RAW_DECL_STRSIGNAL 1
-
-/* Define to 1 if strtod is declared even after undefining macros. */
-#define HAVE_RAW_DECL_STRTOD 1
-
-/* Define to 1 if strtoimax is declared even after undefining macros. */
-#define HAVE_RAW_DECL_STRTOIMAX 1
-
-/* Define to 1 if strtok_r is declared even after undefining macros. */
-#define HAVE_RAW_DECL_STRTOK_R 1
-
-/* Define to 1 if strtoll is declared even after undefining macros. */
-#define HAVE_RAW_DECL_STRTOLL 1
-
-/* Define to 1 if strtoull is declared even after undefining macros. */
-#define HAVE_RAW_DECL_STRTOULL 1
-
-/* Define to 1 if strtoumax is declared even after undefining macros. */
-#define HAVE_RAW_DECL_STRTOUMAX 1
-
-/* Define to 1 if strverscmp is declared even after undefining macros. */
-#define HAVE_RAW_DECL_STRVERSCMP 1
-
-/* Define to 1 if symlink is declared even after undefining macros. */
-#define HAVE_RAW_DECL_SYMLINK 1
-
-/* Define to 1 if symlinkat is declared even after undefining macros. */
-#define HAVE_RAW_DECL_SYMLINKAT 1
-
-/* Define to 1 if tmpfile is declared even after undefining macros. */
-#define HAVE_RAW_DECL_TMPFILE 1
-
-/* Define to 1 if towctrans is declared even after undefining macros. */
-#define HAVE_RAW_DECL_TOWCTRANS 1
-
-/* Define to 1 if ttyname_r is declared even after undefining macros. */
-#define HAVE_RAW_DECL_TTYNAME_R 1
-
-/* Define to 1 if unlink is declared even after undefining macros. */
-#define HAVE_RAW_DECL_UNLINK 1
-
-/* Define to 1 if unlinkat is declared even after undefining macros. */
-#define HAVE_RAW_DECL_UNLINKAT 1
-
-/* Define to 1 if unlockpt is declared even after undefining macros. */
-#define HAVE_RAW_DECL_UNLOCKPT 1
-
-/* Define to 1 if unsetenv is declared even after undefining macros. */
-#define HAVE_RAW_DECL_UNSETENV 1
-
-/* Define to 1 if usleep is declared even after undefining macros. */
-#define HAVE_RAW_DECL_USLEEP 1
-
-/* Define to 1 if utimensat is declared even after undefining macros. */
-#define HAVE_RAW_DECL_UTIMENSAT 1
-
-/* Define to 1 if vdprintf is declared even after undefining macros. */
-#define HAVE_RAW_DECL_VDPRINTF 1
-
-/* Define to 1 if vsnprintf is declared even after undefining macros. */
-#define HAVE_RAW_DECL_VSNPRINTF 1
-
-/* Define to 1 if waitpid is declared even after undefining macros. */
-#define HAVE_RAW_DECL_WAITPID 1
-
-/* Define to 1 if wcpcpy is declared even after undefining macros. */
-#define HAVE_RAW_DECL_WCPCPY 1
-
-/* Define to 1 if wcpncpy is declared even after undefining macros. */
-#define HAVE_RAW_DECL_WCPNCPY 1
-
-/* Define to 1 if wcrtomb is declared even after undefining macros. */
-#define HAVE_RAW_DECL_WCRTOMB 1
-
-/* Define to 1 if wcscasecmp is declared even after undefining macros. */
-#define HAVE_RAW_DECL_WCSCASECMP 1
-
-/* Define to 1 if wcscat is declared even after undefining macros. */
-#define HAVE_RAW_DECL_WCSCAT 1
-
-/* Define to 1 if wcschr is declared even after undefining macros. */
-#define HAVE_RAW_DECL_WCSCHR 1
-
-/* Define to 1 if wcscmp is declared even after undefining macros. */
-#define HAVE_RAW_DECL_WCSCMP 1
-
-/* Define to 1 if wcscoll is declared even after undefining macros. */
-#define HAVE_RAW_DECL_WCSCOLL 1
-
-/* Define to 1 if wcscpy is declared even after undefining macros. */
-#define HAVE_RAW_DECL_WCSCPY 1
-
-/* Define to 1 if wcscspn is declared even after undefining macros. */
-#define HAVE_RAW_DECL_WCSCSPN 1
-
-/* Define to 1 if wcsdup is declared even after undefining macros. */
-#define HAVE_RAW_DECL_WCSDUP 1
-
-/* Define to 1 if wcslen is declared even after undefining macros. */
-#define HAVE_RAW_DECL_WCSLEN 1
-
-/* Define to 1 if wcsncasecmp is declared even after undefining macros. */
-#define HAVE_RAW_DECL_WCSNCASECMP 1
-
-/* Define to 1 if wcsncat is declared even after undefining macros. */
-#define HAVE_RAW_DECL_WCSNCAT 1
-
-/* Define to 1 if wcsncmp is declared even after undefining macros. */
-#define HAVE_RAW_DECL_WCSNCMP 1
-
-/* Define to 1 if wcsncpy is declared even after undefining macros. */
-#define HAVE_RAW_DECL_WCSNCPY 1
-
-/* Define to 1 if wcsnlen is declared even after undefining macros. */
-#define HAVE_RAW_DECL_WCSNLEN 1
-
-/* Define to 1 if wcsnrtombs is declared even after undefining macros. */
-#define HAVE_RAW_DECL_WCSNRTOMBS 1
-
-/* Define to 1 if wcspbrk is declared even after undefining macros. */
-#define HAVE_RAW_DECL_WCSPBRK 1
-
-/* Define to 1 if wcsrchr is declared even after undefining macros. */
-#define HAVE_RAW_DECL_WCSRCHR 1
-
-/* Define to 1 if wcsrtombs is declared even after undefining macros. */
-#define HAVE_RAW_DECL_WCSRTOMBS 1
-
-/* Define to 1 if wcsspn is declared even after undefining macros. */
-#define HAVE_RAW_DECL_WCSSPN 1
-
-/* Define to 1 if wcsstr is declared even after undefining macros. */
-#define HAVE_RAW_DECL_WCSSTR 1
-
-/* Define to 1 if wcstok is declared even after undefining macros. */
-#define HAVE_RAW_DECL_WCSTOK 1
-
-/* Define to 1 if wcswidth is declared even after undefining macros. */
-#define HAVE_RAW_DECL_WCSWIDTH 1
-
-/* Define to 1 if wcsxfrm is declared even after undefining macros. */
-#define HAVE_RAW_DECL_WCSXFRM 1
-
-/* Define to 1 if wctob is declared even after undefining macros. */
-#define HAVE_RAW_DECL_WCTOB 1
-
-/* Define to 1 if wctrans is declared even after undefining macros. */
-#define HAVE_RAW_DECL_WCTRANS 1
-
-/* Define to 1 if wctype is declared even after undefining macros. */
-#define HAVE_RAW_DECL_WCTYPE 1
-
-/* Define to 1 if wcwidth is declared even after undefining macros. */
-#define HAVE_RAW_DECL_WCWIDTH 1
-
-/* Define to 1 if wmemchr is declared even after undefining macros. */
-#define HAVE_RAW_DECL_WMEMCHR 1
-
-/* Define to 1 if wmemcmp is declared even after undefining macros. */
-#define HAVE_RAW_DECL_WMEMCMP 1
-
-/* Define to 1 if wmemcpy is declared even after undefining macros. */
-#define HAVE_RAW_DECL_WMEMCPY 1
-
-/* Define to 1 if wmemmove is declared even after undefining macros. */
-#define HAVE_RAW_DECL_WMEMMOVE 1
-
-/* Define to 1 if wmemset is declared even after undefining macros. */
-#define HAVE_RAW_DECL_WMEMSET 1
-
-/* Define to 1 if _Exit is declared even after undefining macros. */
-#define HAVE_RAW_DECL__EXIT 1
-
-/* Define to 1 if you have the header file. */
-#define HAVE_READLINE_READLINE_H 1
+/* Define to 1 if you have the `rawmemchr' function. */
+#define HAVE_RAWMEMCHR 1
-/* Define to 1 if you have the 'readlink' function. */
+/* Define to 1 if you have the `readlink' function. */
#define HAVE_READLINK 1
-/* Define to 1 if you have the 'realpath' function. */
+/* Define to 1 if you have the `realpath' function. */
#define HAVE_REALPATH 1
-/* Define to 1 if you have the `rl_completion_matches' function. */
-#define HAVE_RL_COMPLETION_MATCHES 1
-
-/* Define to 1 if you have the `rl_crlf' function. */
-#define HAVE_RL_CRLF 1
-
-/* Define to 1 if you have the `rl_replace_line' function. */
-#define HAVE_RL_REPLACE_LINE 1
+/* Define to 1 if the system has the type `sa_family_t'. */
+#define HAVE_SA_FAMILY_T 1
/* Define to 1 if you have the header file. */
#define HAVE_SEARCH_H 1
-/* Define to 1 if you have the 'secure_getenv' function. */
-#define HAVE_SECURE_GETENV 1
-
/* Define to 1 if you have the header file. */
/* #undef HAVE_SELINUX_CONTEXT_H */
/* Define to 1 if you have the header file. */
-/* #undef HAVE_SELINUX_SELINUX_H */
+#define HAVE_SELINUX_SELINUX_H 0
/* Define to 1 if you have the header file. */
#define HAVE_SEMAPHORE_H 1
@@ -1090,11 +683,23 @@
/* Define to 1 if you have the `setdtablesize' function. */
/* #undef HAVE_SETDTABLESIZE */
-/* Define to 1 if you have the 'setenv' function. */
+/* Define to 1 if you have the `setenv' function. */
#define HAVE_SETENV 1
-/* Define to 1 if you have the `setlocale' function. */
-#define HAVE_SETLOCALE 1
+/* Define to 1 if you have the `shutdown' function. */
+#define HAVE_SHUTDOWN 1
+
+/* Define to 1 if you have the `sigaction' function. */
+#define HAVE_SIGACTION 1
+
+/* Define to 1 if you have the `sigaltstack' function. */
+#define HAVE_SIGALTSTACK 1
+
+/* Define to 1 if the system has the type `siginfo_t'. */
+/* #undef HAVE_SIGINFO_T */
+
+/* Define to 1 if you have the `siginterrupt' function. */
+#define HAVE_SIGINTERRUPT 1
/* Define to 1 if 'sig_atomic_t' is a signed integer type. */
/* #undef HAVE_SIGNED_SIG_ATOMIC_T */
@@ -1105,10 +710,13 @@
/* Define to 1 if 'wint_t' is a signed integer type. */
/* #undef HAVE_SIGNED_WINT_T */
-/* Define to 1 if you have the 'sleep' function. */
+/* Define to 1 if the system has the type `sigset_t'. */
+#define HAVE_SIGSET_T 1
+
+/* Define to 1 if you have the `sleep' function. */
#define HAVE_SLEEP 1
-/* Define to 1 if you have the 'snprintf' function. */
+/* Define to 1 if you have the `snprintf' function. */
#define HAVE_SNPRINTF 1
/* Define if the return value of the snprintf function is the number of of
@@ -1116,6 +724,9 @@
buffer had been large enough. */
#define HAVE_SNPRINTF_RETVAL_C99 1
+/* Define if the locale_t type is as on Solaris 11.4. */
+/* #undef HAVE_SOLARIS114_LOCALES */
+
/* Define to 1 if you have the header file. */
#define HAVE_STDINT_H 1
@@ -1144,7 +755,7 @@
/* Define to 1 if you have the header file. */
#define HAVE_STRING_H 1
-/* Define to 1 if you have the 'strndup' function. */
+/* Define to 1 if you have the `strndup' function. */
#define HAVE_STRNDUP 1
/* Define to 1 if you have the `strnlen' function. */
@@ -1153,36 +764,75 @@
/* Define to 1 if `decimal_point' is a member of `struct lconv'. */
/* #undef HAVE_STRUCT_LCONV_DECIMAL_POINT */
-/* Define to 1 if you have the 'symlink' function. */
+/* Define to 1 if `sa_sigaction' is a member of `struct sigaction'. */
+#define HAVE_STRUCT_SIGACTION_SA_SIGACTION 1
+
+/* Define to 1 if the system has the type `struct sockaddr_storage'. */
+#define HAVE_STRUCT_SOCKADDR_STORAGE 1
+
+/* Define to 1 if `ss_family' is a member of `struct sockaddr_storage'. */
+#define HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY 1
+
+/* Define to 1 if `st_atimensec' is a member of `struct stat'. */
+/* #undef HAVE_STRUCT_STAT_ST_ATIMENSEC */
+
+/* Define to 1 if `st_atimespec.tv_nsec' is a member of `struct stat'. */
+/* #undef HAVE_STRUCT_STAT_ST_ATIMESPEC_TV_NSEC */
+
+/* Define to 1 if `st_atim.st__tim.tv_nsec' is a member of `struct stat'. */
+/* #undef HAVE_STRUCT_STAT_ST_ATIM_ST__TIM_TV_NSEC */
+
+/* Define to 1 if `st_atim.tv_nsec' is a member of `struct stat'. */
+#define HAVE_STRUCT_STAT_ST_ATIM_TV_NSEC 1
+
+/* Define to 1 if `st_birthtimensec' is a member of `struct stat'. */
+/* #undef HAVE_STRUCT_STAT_ST_BIRTHTIMENSEC */
+
+/* Define to 1 if `st_birthtimespec.tv_nsec' is a member of `struct stat'. */
+/* #undef HAVE_STRUCT_STAT_ST_BIRTHTIMESPEC_TV_NSEC */
+
+/* Define to 1 if `st_birthtim.tv_nsec' is a member of `struct stat'. */
+/* #undef HAVE_STRUCT_STAT_ST_BIRTHTIM_TV_NSEC */
+
+/* Define to 1 if you have the `symlink' function. */
#define HAVE_SYMLINK 1
/* Define to 1 if you have the header file. */
/* #undef HAVE_SYS_BITYPES_H */
+/* Define to 1 if you have the header file. */
+#define HAVE_SYS_CDEFS_H 1
+
/* Define to 1 if you have the header file. */
/* #undef HAVE_SYS_INTTYPES_H */
+/* Define to 1 if you have the header file. */
+#define HAVE_SYS_IOCTL_H 1
+
/* Define to 1 if you have the header file. */
#define HAVE_SYS_MMAN_H 1
/* Define to 1 if you have the header file. */
#define HAVE_SYS_PARAM_H 1
+/* Define to 1 if you have the header file. */
+#define HAVE_SYS_SELECT_H 1
+
/* Define to 1 if you have the header file. */
#define HAVE_SYS_SOCKET_H 1
/* Define to 1 if you have the header file. */
#define HAVE_SYS_STAT_H 1
-/* Define to 1 if you have the header file. */
-/* #undef HAVE_SYS_TIMEB_H */
-
/* Define to 1 if you have the header file. */
#define HAVE_SYS_TIME_H 1
/* Define to 1 if you have the header file. */
#define HAVE_SYS_TYPES_H 1
+/* Define to 1 if you have the header file. */
+#define HAVE_SYS_UIO_H 1
+
/* Define to 1 if you have the header file. */
#define HAVE_SYS_WAIT_H 1
@@ -1204,10 +854,10 @@
/* Define to 1 if you have the `uselocale' function. */
#define HAVE_USELOCALE 1
-/* Define to 1 if you have the 'usleep' function. */
+/* Define to 1 if you have the `usleep' function. */
#define HAVE_USLEEP 1
-/* Define to 1 if you have the 'vasnprintf' function. */
+/* Define to 1 if you have the `vasnprintf' function. */
/* #undef HAVE_VASNPRINTF */
/* Define to 1 if you have the `vasprintf' function. */
@@ -1219,7 +869,7 @@
/* Define if you have the 'wchar_t' type. */
#define HAVE_WCHAR_T 1
-/* Define to 1 if you have the 'wcrtomb' function. */
+/* Define to 1 if you have the `wcrtomb' function. */
#define HAVE_WCRTOMB 1
/* Define to 1 if you have the `wcslen' function. */
@@ -1228,7 +878,7 @@
/* Define to 1 if you have the `wcsnlen' function. */
#define HAVE_WCSNLEN 1
-/* Define to 1 if you have the 'wctob' function. */
+/* Define to 1 if you have the `wctob' function. */
#define HAVE_WCTOB 1
/* Define to 1 if you have the header file. */
@@ -1240,13 +890,13 @@
/* Define if you have the 'wint_t' type. */
#define HAVE_WINT_T 1
-/* Define to 1 if you have the 'wmemchr' function. */
+/* Define to 1 if you have the `wmemchr' function. */
#define HAVE_WMEMCHR 1
-/* Define to 1 if you have the 'wmemcpy' function. */
+/* Define to 1 if you have the `wmemcpy' function. */
#define HAVE_WMEMCPY 1
-/* Define to 1 if you have the 'wmempcpy' function. */
+/* Define to 1 if you have the `wmempcpy' function. */
#define HAVE_WMEMPCPY 1
/* This value is set to 1 to indicate that the system argz facility works */
@@ -1258,16 +908,19 @@
/* Define to 1 if O_NOFOLLOW works. */
#define HAVE_WORKING_O_NOFOLLOW 1
+/* Define if the uselocale function exists any may safely be called. */
+#define HAVE_WORKING_USELOCALE 1
+
+/* Define to 1 if you have the header file. */
+/* #undef HAVE_WS2TCPIP_H */
+
/* Define to 1 if you have the header file. */
-/* #undef HAVE_XLOCALE_H */
+#define HAVE_XLOCALE_H 1
/* Define to 1 if the system has the type `_Bool'. */
#define HAVE__BOOL 1
-/* Define to 1 if you have the `_ftime' function. */
-/* #undef HAVE__FTIME */
-
-/* Define to 1 if you have the '_set_invalid_parameter_handler' function. */
+/* Define to 1 if you have the `_set_invalid_parameter_handler' function. */
/* #undef HAVE__SET_INVALID_PARAMETER_HANDLER */
/* Define to 1 if the compiler supports __builtin_expect,
@@ -1280,8 +933,11 @@
#endif
-/* Define to 1 if you have the `__secure_getenv' function. */
-/* #undef HAVE___SECURE_GETENV */
+/* Define to 1 if the compiler supports the keyword '__inline'. */
+#define HAVE___INLINE 1
+
+/* Define to 1 if you have the `__xpg_strerror_r' function. */
+#define HAVE___XPG_STRERROR_R 1
/* Define to 1 if 'lstat' dereferences a symlink specified with a trailing
slash. */
@@ -1331,7 +987,7 @@
#define PACKAGE_NAME "augeas"
/* Define to the full name and version of this package. */
-#define PACKAGE_STRING "augeas 1.9.0"
+#define PACKAGE_STRING "augeas 1.12.0"
/* Define to the one symbol short name of this package. */
#define PACKAGE_TARNAME "augeas"
@@ -1340,7 +996,7 @@
#define PACKAGE_URL ""
/* Define to the version of this package. */
-#define PACKAGE_VERSION "1.9.0"
+#define PACKAGE_VERSION "1.12.0"
/* Define if exists and defines unusable PRI* macros. */
/* #undef PRI_MACROS_BROKEN */
@@ -1352,6 +1008,16 @@
/* Define if the pthread_in_use() detection is hard. */
/* #undef PTHREAD_IN_USE_DETECTION_HARD */
+/* Define to 1 if pthread_sigmask(), when it fails, returns -1 and sets errno.
+ */
+/* #undef PTHREAD_SIGMASK_FAILS_WITH_ERRNO */
+
+/* Define to 1 if pthread_sigmask may return 0 and have no effect. */
+/* #undef PTHREAD_SIGMASK_INEFFECTIVE */
+
+/* Define to 1 if pthread_sigmask() unblocks signals incorrectly. */
+/* #undef PTHREAD_SIGMASK_UNBLOCK_BUG */
+
/* Define to l, ll, u, ul, ull, etc., as suitable for constants of type
'ptrdiff_t'. */
/* #undef PTRDIFF_T_SUFFIX */
@@ -1359,16 +1025,15 @@
/* Define to 1 if readlink fails to recognize a trailing slash. */
/* #undef READLINK_TRAILING_SLASH_BUG */
-/* Define to 1 if stat needs help when passed a directory name with a trailing
- slash */
-/* #undef REPLACE_FUNC_STAT_DIR */
-
/* Define to 1 if stat needs help when passed a file name with a trailing
slash */
/* #undef REPLACE_FUNC_STAT_FILE */
/* Define if nl_langinfo exists but is overridden by gnulib. */
-/* #undef REPLACE_NL_LANGINFO */
+#define REPLACE_NL_LANGINFO 1
+
+/* Define to 1 if strerror(0) does not return a message implying success. */
+/* #undef REPLACE_STRERROR_0 */
/* Define if vasnprintf exists but is overridden by gnulib. */
/* #undef REPLACE_VASNPRINTF */
@@ -1401,6 +1066,10 @@
/* Define to 1 if you have the ANSI C header files. */
#define STDC_HEADERS 1
+/* Define to 1 if the type of the st_atim member of a struct stat is struct
+ timespec. */
+#define TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC 1
+
/* Define if the POSIX multithreading library can be used. */
#define USE_POSIX_THREADS 1
@@ -1434,6 +1103,14 @@
#ifndef _GNU_SOURCE
# define _GNU_SOURCE 1
#endif
+/* Enable NetBSD extensions on NetBSD. */
+#ifndef _NETBSD_SOURCE
+# define _NETBSD_SOURCE 1
+#endif
+/* Enable OpenBSD extensions on NetBSD. */
+#ifndef _OPENBSD_SOURCE
+# define _OPENBSD_SOURCE 1
+#endif
/* Enable threading extensions on Solaris. */
#ifndef _POSIX_PTHREAD_SEMANTICS
# define _POSIX_PTHREAD_SEMANTICS 1
@@ -1476,6 +1153,11 @@
#ifndef _XOPEN_SOURCE
/* # undef _XOPEN_SOURCE */
#endif
+/* Enable X/Open compliant socket functions that do not require linking
+ with -lxnet on HP-UX 11.11. */
+#ifndef _HPUX_ALT_XOPEN_SOCKET_API
+# define _HPUX_ALT_XOPEN_SOCKET_API 1
+#endif
/* Enable general extensions on Solaris. */
#ifndef __EXTENSIONS__
# define __EXTENSIONS__ 1
@@ -1486,7 +1168,7 @@
/* #undef USE_WINDOWS_THREADS */
/* Version number of package */
-#define VERSION "1.9.0"
+#define VERSION "1.12.0"
/* Define to 1 if unsetenv returns void instead of int. */
/* #undef VOID_UNSETENV */
@@ -1495,6 +1177,9 @@
'wchar_t'. */
/* #undef WCHAR_T_SUFFIX */
+/* Define if WSAStartup is needed. */
+/* #undef WINDOWS_SOCKETS */
+
/* Define to l, ll, u, ul, ull, etc., as suitable for constants of type
'wint_t'. */
/* #undef WINT_T_SUFFIX */
@@ -1513,7 +1198,7 @@
/* Define to 1 if `lex' declares `yytext' as a `char *' by default, not a
`char[]'. */
-#define YYTEXT_POINTER 1
+/* #undef YYTEXT_POINTER */
/* Enable large inode numbers on Mac OS X 10.5. */
#define _DARWIN_USE_64_BIT_INODE 1
@@ -1521,10 +1206,6 @@
/* Number of bits in a file offset, on hosts where this is settable. */
/* #undef _FILE_OFFSET_BITS */
-/* Define to 1 if Gnulib overrides 'struct stat' on Windows so that struct
- stat.st_size becomes 64-bit. */
-/* #undef _GL_WINDOWS_64_BIT_ST_SIZE */
-
/* Define for large files, on AIX-style hosts. */
/* #undef _LARGE_FILES */
@@ -1535,15 +1216,21 @@
/* #undef _MINIX */
/* Define to 1 to make NetBSD features available. MINIX 3 needs this. */
-/* #undef _NETBSD_SOURCE */
+#define _NETBSD_SOURCE 1
/* The _Noreturn keyword of C11. */
-#if ! (defined _Noreturn \
- || (defined __STDC_VERSION__ && 201112 <= __STDC_VERSION__))
-# if (3 <= __GNUC__ || (__GNUC__ == 2 && 8 <= __GNUC_MINOR__) \
- || 0x5110 <= __SUNPRO_C)
+#ifndef _Noreturn
+# if (defined __cplusplus \
+ && ((201103 <= __cplusplus && !(__GNUC__ == 4 && __GNUC_MINOR__ == 7)) \
+ || (defined _MSC_VER && 1900 <= _MSC_VER)))
+# define _Noreturn [[noreturn]]
+# elif ((!defined __cplusplus || defined __clang__) \
+ && (201112 <= (defined __STDC_VERSION__ ? __STDC_VERSION__ : 0) \
+ || 4 < __GNUC__ + (7 <= __GNUC_MINOR__)))
+ /* _Noreturn works as-is. */
+# elif 2 < __GNUC__ + (8 <= __GNUC_MINOR__) || 0x5110 <= __SUNPRO_C
# define _Noreturn __attribute__ ((__noreturn__))
-# elif defined _MSC_VER && 1200 <= _MSC_VER
+# elif 1200 <= (defined _MSC_VER ? _MSC_VER : 0)
# define _Noreturn __declspec (noreturn)
# else
# define _Noreturn
@@ -1555,15 +1242,22 @@
this defined. */
/* #undef _POSIX_1_SOURCE */
+/* Define to 1 in order to get the POSIX compatible declarations of socket
+ functions. */
+/* #undef _POSIX_PII_SOCKET */
+
/* Define to 1 if you need to in order for 'stat' and other things to work. */
/* #undef _POSIX_SOURCE */
/* Define if you want to include , so that it consistently
overrides 's RE_DUP_MAX. */
-/* #undef _REGEX_INCLUDE_LIMITS_H */
+#define _REGEX_INCLUDE_LIMITS_H 1
/* Define if you want regoff_t to be at least as wide POSIX requires. */
-/* #undef _REGEX_LARGE_OFFSETS */
+#define _REGEX_LARGE_OFFSETS 1
+
+/* For standard stat data types on VMS. */
+#define _USE_STD_STAT 1
/* Define to rpl_ if the getopt replacement functions and variables should be
used. */
@@ -1578,13 +1272,40 @@
/* Define so that glibc/gnulib argp.h does not typedef error_t. */
/* #undef __error_t_defined */
+/* The _GL_ASYNC_SAFE marker should be attached to functions that are
+ signal handlers (for signals other than SIGABRT, SIGPIPE) or can be
+ invoked from such signal handlers. Such functions have some restrictions:
+ * All functions that it calls should be marked _GL_ASYNC_SAFE as well,
+ or should be listed as async-signal-safe in POSIX
+
+ section 2.4.3. Note that malloc(), sprintf(), and fwrite(), in
+ particular, are NOT async-signal-safe.
+ * All memory locations (variables and struct fields) that these functions
+ access must be marked 'volatile'. This holds for both read and write
+ accesses. Otherwise the compiler might optimize away stores to and
+ reads from such locations that occur in the program, depending on its
+ data flow analysis. For example, when the program contains a loop
+ that is intended to inspect a variable set from within a signal handler
+ while (!signal_occurred)
+ ;
+ the compiler is allowed to transform this into an endless loop if the
+ variable 'signal_occurred' is not declared 'volatile'.
+ Additionally, recall that:
+ * A signal handler should not modify errno (except if it is a handler
+ for a fatal signal and ends by raising the same signal again, thus
+ provoking the termination of the process). If it invokes a function
+ that may clobber errno, it needs to save and restore the value of
+ errno. */
+#define _GL_ASYNC_SAFE
+
+
/* Define to a type to use for 'error_t' if it is not otherwise available. */
/* #undef error_t */
/* Please see the Gnulib manual for how to use these macros.
Suppress extern inline with HP-UX cc, as it appears to be broken; see
- .
+ .
Suppress extern inline with Sun C in standards-conformance mode, as it
mishandles inline functions that call each other. E.g., for 'inline void f
@@ -1598,20 +1319,32 @@
if isdigit is mistakenly implemented via a static inline function,
a program containing an extern inline function that calls isdigit
may not work since the C standard prohibits extern inline functions
- from calling static functions. This bug is known to occur on:
+ from calling static functions (ISO C 99 section 6.7.4.(3).
+ This bug is known to occur on:
OS X 10.8 and earlier; see:
- http://lists.gnu.org/archive/html/bug-gnulib/2012-12/msg00023.html
+ https://lists.gnu.org/r/bug-gnulib/2012-12/msg00023.html
DragonFly; see
http://muscles.dragonflybsd.org/bulk/bleeding-edge-potential/latest-per-pkg/ah-tty-0.3.12.log
FreeBSD; see:
- http://lists.gnu.org/archive/html/bug-gnulib/2014-07/msg00104.html
+ https://lists.gnu.org/r/bug-gnulib/2014-07/msg00104.html
OS X 10.9 has a macro __header_inline indicating the bug is fixed for C and
- for clang but remains for g++; see .
- Assume DragonFly and FreeBSD will be similar. */
+ for clang but remains for g++; see .
+ Assume DragonFly and FreeBSD will be similar.
+
+ GCC 4.3 and above with -std=c99 or -std=gnu99 implements ISO C99
+ inline semantics, unless -fgnu89-inline is used. It defines a macro
+ __GNUC_STDC_INLINE__ to indicate this situation or a macro
+ __GNUC_GNU_INLINE__ to indicate the opposite situation.
+ GCC 4.2 with -std=c99 or -std=gnu99 implements the GNU C inline
+ semantics but warns, unless -fgnu89-inline is used:
+ warning: C99 inline functions are not supported; using GNU89
+ warning: to disable this warning use -fgnu89-inline or the gnu_inline function attribute
+ It defines a macro __GNUC_GNU_INLINE__ to indicate this situation.
+ */
#if (((defined __APPLE__ && defined __MACH__) \
|| defined __DragonFly__ || defined __FreeBSD__) \
&& (defined __header_inline \
@@ -1676,12 +1409,12 @@
/* Always use our fgetfilecon wrapper. */
/* #undef fgetfilecon */
-/* Define to a replacement function name for fnmatch(). */
-/* #undef fnmatch */
-
/* Always use our getfilecon wrapper. */
/* #undef getfilecon */
+/* Define to `int' if doesn't define. */
+/* #undef gid_t */
+
/* Define to `__inline__' or `__inline' if that's what the C compiler
calls it, or to nothing if 'inline' is not supported under any name. */
#ifndef __cplusplus
@@ -1721,49 +1454,49 @@
/* #undef ptrdiff_t */
/* Define to rpl_re_comp if the replacement should be used. */
-/* #undef re_comp */
+#define re_comp rpl_re_comp
/* Define to rpl_re_compile_fastmap if the replacement should be used. */
-/* #undef re_compile_fastmap */
+#define re_compile_fastmap rpl_re_compile_fastmap
/* Define to rpl_re_compile_pattern if the replacement should be used. */
-/* #undef re_compile_pattern */
+#define re_compile_pattern rpl_re_compile_pattern
/* Define to rpl_re_exec if the replacement should be used. */
-/* #undef re_exec */
+#define re_exec rpl_re_exec
/* Define to rpl_re_match if the replacement should be used. */
-/* #undef re_match */
+#define re_match rpl_re_match
/* Define to rpl_re_match_2 if the replacement should be used. */
-/* #undef re_match_2 */
+#define re_match_2 rpl_re_match_2
/* Define to rpl_re_search if the replacement should be used. */
-/* #undef re_search */
+#define re_search rpl_re_search
/* Define to rpl_re_search_2 if the replacement should be used. */
-/* #undef re_search_2 */
+#define re_search_2 rpl_re_search_2
/* Define to rpl_re_set_registers if the replacement should be used. */
-/* #undef re_set_registers */
+#define re_set_registers rpl_re_set_registers
/* Define to rpl_re_set_syntax if the replacement should be used. */
-/* #undef re_set_syntax */
+#define re_set_syntax rpl_re_set_syntax
/* Define to rpl_re_syntax_options if the replacement should be used. */
-/* #undef re_syntax_options */
+#define re_syntax_options rpl_re_syntax_options
/* Define to rpl_regcomp if the replacement should be used. */
-/* #undef regcomp */
+#define regcomp rpl_regcomp
/* Define to rpl_regerror if the replacement should be used. */
-/* #undef regerror */
+#define regerror rpl_regerror
/* Define to rpl_regexec if the replacement should be used. */
-/* #undef regexec */
+#define regexec rpl_regexec
/* Define to rpl_regfree if the replacement should be used. */
-/* #undef regfree */
+#define regfree rpl_regfree
/* Define to the equivalent of the C99 'restrict' keyword, or to
nothing if this is not supported. Do not define if restrict is
@@ -1782,9 +1515,15 @@
/* Define to `unsigned int' if does not define. */
/* #undef size_t */
+/* type to use in place of socklen_t if not defined */
+/* #undef socklen_t */
+
/* Define as a signed type of the same size as size_t. */
/* #undef ssize_t */
+/* Define to `int' if doesn't define. */
+/* #undef uid_t */
+
/* Define as a marker that can be attached to declarations that might not
be used. This helps to reduce warnings, such as from
GCC -Wunused-parameter. */
@@ -1821,6 +1560,13 @@
# define _GL_ATTRIBUTE_CONST /* empty */
#endif
+/* The __malloc__ attribute was added in gcc 3. */
+#if 3 <= __GNUC__
+# define _GL_ATTRIBUTE_MALLOC __attribute__ ((__malloc__))
+#else
+# define _GL_ATTRIBUTE_MALLOC /* empty */
+#endif
+
/* Define to an unsigned 32-bit type if lacks this type. */
/* #undef useconds_t */
diff --git a/libraries/cmake/source/augeas/config/datadir.h b/libraries/cmake/source/augeas/generated/linux/aarch64/config/datadir.h
similarity index 100%
rename from libraries/cmake/source/augeas/config/datadir.h
rename to libraries/cmake/source/augeas/generated/linux/aarch64/config/datadir.h
diff --git a/libraries/cmake/source/augeas/generated/linux/x86_64/code/lexer.c b/libraries/cmake/source/augeas/generated/linux/x86_64/code/lexer.c
new file mode 100644
index 00000000000..ea1e331cfe7
--- /dev/null
+++ b/libraries/cmake/source/augeas/generated/linux/x86_64/code/lexer.c
@@ -0,0 +1,2312 @@
+#line 2 "lexer.c"
+#line 10 "lexer.l"
+/* config.h must precede flex's inclusion of
+ in order for its _GNU_SOURCE definition to take effect. */
+#include
+
+
+
+#line 10 "lexer.c"
+
+#define YY_INT_ALIGNED short int
+
+/* A lexical scanner generated by flex */
+
+#define FLEX_SCANNER
+#define YY_FLEX_MAJOR_VERSION 2
+#define YY_FLEX_MINOR_VERSION 5
+#define YY_FLEX_SUBMINOR_VERSION 35
+#if YY_FLEX_SUBMINOR_VERSION > 0
+#define FLEX_BETA
+#endif
+
+/* First, we deal with platform-specific or compiler-specific issues. */
+
+/* begin standard C headers. */
+#include
+#include
+#include
+#include
+
+/* end standard C headers. */
+
+/* flex integer type definitions */
+
+#ifndef FLEXINT_H
+#define FLEXINT_H
+
+/* C99 systems have . Non-C99 systems may or may not. */
+
+#if defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
+
+/* C99 says to define __STDC_LIMIT_MACROS before including stdint.h,
+ * if you want the limit (max/min) macros for int types.
+ */
+#ifndef __STDC_LIMIT_MACROS
+#define __STDC_LIMIT_MACROS 1
+#endif
+
+#include
+typedef int8_t flex_int8_t;
+typedef uint8_t flex_uint8_t;
+typedef int16_t flex_int16_t;
+typedef uint16_t flex_uint16_t;
+typedef int32_t flex_int32_t;
+typedef uint32_t flex_uint32_t;
+#else
+typedef signed char flex_int8_t;
+typedef short int flex_int16_t;
+typedef int flex_int32_t;
+typedef unsigned char flex_uint8_t;
+typedef unsigned short int flex_uint16_t;
+typedef unsigned int flex_uint32_t;
+#endif /* ! C99 */
+
+/* Limits of integral types. */
+#ifndef INT8_MIN
+#define INT8_MIN (-128)
+#endif
+#ifndef INT16_MIN
+#define INT16_MIN (-32767-1)
+#endif
+#ifndef INT32_MIN
+#define INT32_MIN (-2147483647-1)
+#endif
+#ifndef INT8_MAX
+#define INT8_MAX (127)
+#endif
+#ifndef INT16_MAX
+#define INT16_MAX (32767)
+#endif
+#ifndef INT32_MAX
+#define INT32_MAX (2147483647)
+#endif
+#ifndef UINT8_MAX
+#define UINT8_MAX (255U)
+#endif
+#ifndef UINT16_MAX
+#define UINT16_MAX (65535U)
+#endif
+#ifndef UINT32_MAX
+#define UINT32_MAX (4294967295U)
+#endif
+
+#endif /* ! FLEXINT_H */
+
+#ifdef __cplusplus
+
+/* The "const" storage-class-modifier is valid. */
+#define YY_USE_CONST
+
+#else /* ! __cplusplus */
+
+/* C99 requires __STDC__ to be defined as 1. */
+#if defined (__STDC__)
+
+#define YY_USE_CONST
+
+#endif /* defined (__STDC__) */
+#endif /* ! __cplusplus */
+
+#ifdef YY_USE_CONST
+#define yyconst const
+#else
+#define yyconst
+#endif
+
+/* Returned upon end-of-file. */
+#define YY_NULL 0
+
+/* Promotes a possibly negative, possibly signed char to an unsigned
+ * integer for use as an array index. If the signed char is negative,
+ * we want to instead treat it as an 8-bit unsigned char, hence the
+ * double cast.
+ */
+#define YY_SC_TO_UI(c) ((unsigned int) (unsigned char) c)
+
+/* An opaque pointer. */
+#ifndef YY_TYPEDEF_YY_SCANNER_T
+#define YY_TYPEDEF_YY_SCANNER_T
+typedef void* yyscan_t;
+#endif
+
+/* For convenience, these vars (plus the bison vars far below)
+ are macros in the reentrant scanner. */
+#define yyin yyg->yyin_r
+#define yyout yyg->yyout_r
+#define yyextra yyg->yyextra_r
+#define yyleng yyg->yyleng_r
+#define yytext yyg->yytext_r
+#define yylineno (YY_CURRENT_BUFFER_LVALUE->yy_bs_lineno)
+#define yycolumn (YY_CURRENT_BUFFER_LVALUE->yy_bs_column)
+#define yy_flex_debug yyg->yy_flex_debug_r
+
+/* Enter a start condition. This macro really ought to take a parameter,
+ * but we do it the disgusting crufty way forced on us by the ()-less
+ * definition of BEGIN.
+ */
+#define BEGIN yyg->yy_start = 1 + 2 *
+
+/* Translate the current start state into a value that can be later handed
+ * to BEGIN to return to the state. The YYSTATE alias is for lex
+ * compatibility.
+ */
+#define YY_START ((yyg->yy_start - 1) / 2)
+#define YYSTATE YY_START
+
+/* Action number for EOF rule of a given start state. */
+#define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1)
+
+/* Special action meaning "start processing a new file". */
+#define YY_NEW_FILE augl_restart(yyin ,yyscanner )
+
+#define YY_END_OF_BUFFER_CHAR 0
+
+/* Size of default input buffer. */
+#ifndef YY_BUF_SIZE
+#define YY_BUF_SIZE 16384
+#endif
+
+/* The state buf must be large enough to hold one state per character in the main buffer.
+ */
+#define YY_STATE_BUF_SIZE ((YY_BUF_SIZE + 2) * sizeof(yy_state_type))
+
+#ifndef YY_TYPEDEF_YY_BUFFER_STATE
+#define YY_TYPEDEF_YY_BUFFER_STATE
+typedef struct yy_buffer_state *YY_BUFFER_STATE;
+#endif
+
+#define EOB_ACT_CONTINUE_SCAN 0
+#define EOB_ACT_END_OF_FILE 1
+#define EOB_ACT_LAST_MATCH 2
+
+ /* Note: We specifically omit the test for yy_rule_can_match_eol because it requires
+ * access to the local variable yy_act. Since yyless() is a macro, it would break
+ * existing scanners that call yyless() from OUTSIDE augl_lex.
+ * One obvious solution it to make yy_act a global. I tried that, and saw
+ * a 5% performance hit in a non-yylineno scanner, because yy_act is
+ * normally declared as a register variable-- so it is not worth it.
+ */
+ #define YY_LESS_LINENO(n) \
+ do { \
+ int yyl;\
+ for ( yyl = n; yyl < yyleng; ++yyl )\
+ if ( yytext[yyl] == '\n' )\
+ --yylineno;\
+ }while(0)
+
+/* Return all but the first "n" matched characters back to the input stream. */
+#define yyless(n) \
+ do \
+ { \
+ /* Undo effects of setting up yytext. */ \
+ int yyless_macro_arg = (n); \
+ YY_LESS_LINENO(yyless_macro_arg);\
+ *yy_cp = yyg->yy_hold_char; \
+ YY_RESTORE_YY_MORE_OFFSET \
+ yyg->yy_c_buf_p = yy_cp = yy_bp + yyless_macro_arg - YY_MORE_ADJ; \
+ YY_DO_BEFORE_ACTION; /* set up yytext again */ \
+ } \
+ while ( 0 )
+
+#define unput(c) yyunput( c, yyg->yytext_ptr , yyscanner )
+
+#ifndef YY_TYPEDEF_YY_SIZE_T
+#define YY_TYPEDEF_YY_SIZE_T
+typedef size_t yy_size_t;
+#endif
+
+#ifndef YY_STRUCT_YY_BUFFER_STATE
+#define YY_STRUCT_YY_BUFFER_STATE
+struct yy_buffer_state
+ {
+ FILE *yy_input_file;
+
+ char *yy_ch_buf; /* input buffer */
+ char *yy_buf_pos; /* current position in input buffer */
+
+ /* Size of input buffer in bytes, not including room for EOB
+ * characters.
+ */
+ yy_size_t yy_buf_size;
+
+ /* Number of characters read into yy_ch_buf, not including EOB
+ * characters.
+ */
+ int yy_n_chars;
+
+ /* Whether we "own" the buffer - i.e., we know we created it,
+ * and can realloc() it to grow it, and should free() it to
+ * delete it.
+ */
+ int yy_is_our_buffer;
+
+ /* Whether this is an "interactive" input source; if so, and
+ * if we're using stdio for input, then we want to use getc()
+ * instead of fread(), to make sure we stop fetching input after
+ * each newline.
+ */
+ int yy_is_interactive;
+
+ /* Whether we're considered to be at the beginning of a line.
+ * If so, '^' rules will be active on the next match, otherwise
+ * not.
+ */
+ int yy_at_bol;
+
+ int yy_bs_lineno; /**< The line count. */
+ int yy_bs_column; /**< The column count. */
+
+ /* Whether to try to fill the input buffer when we reach the
+ * end of it.
+ */
+ int yy_fill_buffer;
+
+ int yy_buffer_status;
+
+#define YY_BUFFER_NEW 0
+#define YY_BUFFER_NORMAL 1
+ /* When an EOF's been seen but there's still some text to process
+ * then we mark the buffer as YY_EOF_PENDING, to indicate that we
+ * shouldn't try reading from the input source any more. We might
+ * still have a bunch of tokens to match, though, because of
+ * possible backing-up.
+ *
+ * When we actually see the EOF, we change the status to "new"
+ * (via augl_restart()), so that the user can continue scanning by
+ * just pointing yyin at a new input file.
+ */
+#define YY_BUFFER_EOF_PENDING 2
+
+ };
+#endif /* !YY_STRUCT_YY_BUFFER_STATE */
+
+/* We provide macros for accessing buffer states in case in the
+ * future we want to put the buffer states in a more general
+ * "scanner state".
+ *
+ * Returns the top of the stack, or NULL.
+ */
+#define YY_CURRENT_BUFFER ( yyg->yy_buffer_stack \
+ ? yyg->yy_buffer_stack[yyg->yy_buffer_stack_top] \
+ : NULL)
+
+/* Same as previous macro, but useful when we know that the buffer stack is not
+ * NULL or when we need an lvalue. For internal use only.
+ */
+#define YY_CURRENT_BUFFER_LVALUE yyg->yy_buffer_stack[yyg->yy_buffer_stack_top]
+
+void augl_restart (FILE *input_file ,yyscan_t yyscanner );
+void augl__switch_to_buffer (YY_BUFFER_STATE new_buffer ,yyscan_t yyscanner );
+YY_BUFFER_STATE augl__create_buffer (FILE *file,int size ,yyscan_t yyscanner );
+void augl__delete_buffer (YY_BUFFER_STATE b ,yyscan_t yyscanner );
+void augl__flush_buffer (YY_BUFFER_STATE b ,yyscan_t yyscanner );
+void augl_push_buffer_state (YY_BUFFER_STATE new_buffer ,yyscan_t yyscanner );
+void augl_pop_buffer_state (yyscan_t yyscanner );
+
+static void augl_ensure_buffer_stack (yyscan_t yyscanner );
+static void augl__load_buffer_state (yyscan_t yyscanner );
+static void augl__init_buffer (YY_BUFFER_STATE b,FILE *file ,yyscan_t yyscanner );
+
+#define YY_FLUSH_BUFFER augl__flush_buffer(YY_CURRENT_BUFFER ,yyscanner)
+
+YY_BUFFER_STATE augl__scan_buffer (char *base,yy_size_t size ,yyscan_t yyscanner );
+YY_BUFFER_STATE augl__scan_string (yyconst char *yy_str ,yyscan_t yyscanner );
+YY_BUFFER_STATE augl__scan_bytes (yyconst char *bytes,int len ,yyscan_t yyscanner );
+
+void *augl_alloc (yy_size_t ,yyscan_t yyscanner );
+void *augl_realloc (void *,yy_size_t ,yyscan_t yyscanner );
+void augl_free (void * ,yyscan_t yyscanner );
+
+#define yy_new_buffer augl__create_buffer
+
+#define yy_set_interactive(is_interactive) \
+ { \
+ if ( ! YY_CURRENT_BUFFER ){ \
+ augl_ensure_buffer_stack (yyscanner); \
+ YY_CURRENT_BUFFER_LVALUE = \
+ augl__create_buffer(yyin,YY_BUF_SIZE ,yyscanner); \
+ } \
+ YY_CURRENT_BUFFER_LVALUE->yy_is_interactive = is_interactive; \
+ }
+
+#define yy_set_bol(at_bol) \
+ { \
+ if ( ! YY_CURRENT_BUFFER ){\
+ augl_ensure_buffer_stack (yyscanner); \
+ YY_CURRENT_BUFFER_LVALUE = \
+ augl__create_buffer(yyin,YY_BUF_SIZE ,yyscanner); \
+ } \
+ YY_CURRENT_BUFFER_LVALUE->yy_at_bol = at_bol; \
+ }
+
+#define YY_AT_BOL() (YY_CURRENT_BUFFER_LVALUE->yy_at_bol)
+
+/* Begin user sect3 */
+
+#define augl_wrap(n) 1
+#define YY_SKIP_YYWRAP
+
+typedef unsigned char YY_CHAR;
+
+typedef int yy_state_type;
+
+#define yytext_ptr yytext_r
+
+static yy_state_type yy_get_previous_state (yyscan_t yyscanner );
+static yy_state_type yy_try_NUL_trans (yy_state_type current_state ,yyscan_t yyscanner);
+static int yy_get_next_buffer (yyscan_t yyscanner );
+static void yy_fatal_error (yyconst char msg[] ,yyscan_t yyscanner );
+
+/* Done after the current pattern has been matched and before the
+ * corresponding action - sets up yytext.
+ */
+#define YY_DO_BEFORE_ACTION \
+ yyg->yytext_ptr = yy_bp; \
+ yyleng = (size_t) (yy_cp - yy_bp); \
+ yyg->yy_hold_char = *yy_cp; \
+ *yy_cp = '\0'; \
+ yyg->yy_c_buf_p = yy_cp;
+
+#define YY_NUM_RULES 29
+#define YY_END_OF_BUFFER 30
+/* This struct is not used in this scanner,
+ but its presence is necessary. */
+struct yy_trans_info
+ {
+ flex_int32_t yy_verify;
+ flex_int32_t yy_nxt;
+ };
+static yyconst flex_int16_t yy_accept[95] =
+ { 0,
+ 1, 1, 1, 1, 30, 25, 1, 2, 25, 25,
+ 7, 7, 7, 25, 23, 22, 22, 22, 22, 22,
+ 22, 22, 22, 22, 22, 28, 1, 28, 28, 28,
+ 1, 2, 3, 0, 4, 0, 24, 20, 0, 6,
+ 0, 0, 23, 22, 22, 22, 22, 14, 22, 22,
+ 22, 22, 22, 22, 26, 27, 0, 5, 21, 22,
+ 22, 17, 22, 10, 22, 18, 22, 22, 22, 21,
+ 22, 22, 13, 0, 22, 22, 22, 16, 19, 22,
+ 0, 22, 22, 22, 22, 0, 8, 12, 11, 22,
+ 0, 15, 9, 0
+
+ } ;
+
+static yyconst flex_int32_t yy_ec[256] =
+ { 0,
+ 1, 1, 1, 1, 1, 1, 1, 1, 2, 3,
+ 1, 1, 4, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 2, 1, 5, 1, 1, 1, 1, 1, 6,
+ 7, 8, 9, 1, 10, 11, 12, 13, 13, 13,
+ 13, 13, 13, 13, 13, 13, 13, 9, 9, 1,
+ 9, 14, 9, 1, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 9, 16, 9, 1, 17, 1, 18, 17, 19, 20,
+
+ 21, 22, 23, 17, 24, 17, 17, 25, 26, 27,
+ 28, 29, 17, 30, 31, 32, 33, 17, 17, 34,
+ 17, 17, 9, 9, 9, 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
+ } ;
+
+static yyconst flex_int32_t yy_meta[35] =
+ { 0,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 2, 1, 3, 1, 3, 1, 4, 4, 4, 4,
+ 4, 4, 4, 4, 4, 4, 4, 4, 4, 4,
+ 4, 4, 4, 4
+ } ;
+
+static yyconst flex_int16_t yy_base[102] =
+ { 0,
+ 0, 0, 33, 40, 134, 135, 131, 129, 128, 33,
+ 122, 135, 115, 35, 117, 0, 23, 106, 99, 104,
+ 96, 90, 101, 89, 99, 135, 117, 115, 109, 109,
+ 113, 111, 109, 45, 135, 0, 135, 135, 41, 88,
+ 0, 0, 100, 0, 78, 77, 76, 0, 27, 87,
+ 74, 82, 74, 72, 135, 135, 99, 135, 0, 80,
+ 72, 0, 68, 96, 64, 0, 75, 71, 62, 0,
+ 63, 67, 0, 38, 66, 56, 62, 0, 0, 60,
+ 46, 45, 36, 41, 42, 39, 0, 0, 0, 35,
+ 60, 0, 135, 135, 68, 72, 76, 79, 81, 48,
+
+ 83
+ } ;
+
+static yyconst flex_int16_t yy_def[102] =
+ { 0,
+ 94, 1, 95, 95, 94, 94, 94, 94, 94, 96,
+ 94, 94, 94, 97, 98, 99, 99, 99, 99, 99,
+ 99, 99, 99, 99, 99, 94, 94, 94, 94, 94,
+ 94, 94, 94, 96, 94, 96, 94, 94, 97, 94,
+ 97, 100, 98, 99, 99, 99, 99, 99, 99, 99,
+ 99, 99, 99, 99, 94, 94, 94, 94, 101, 99,
+ 99, 99, 99, 99, 99, 99, 99, 99, 99, 101,
+ 99, 99, 99, 94, 99, 99, 99, 99, 99, 99,
+ 94, 99, 99, 99, 99, 94, 99, 99, 99, 99,
+ 94, 99, 94, 0, 94, 94, 94, 94, 94, 94,
+
+ 94
+ } ;
+
+static yyconst flex_int16_t yy_nxt[170] =
+ { 0,
+ 6, 7, 8, 9, 10, 11, 12, 12, 12, 13,
+ 12, 14, 6, 6, 15, 6, 16, 17, 16, 16,
+ 16, 16, 18, 19, 20, 21, 16, 16, 22, 23,
+ 24, 25, 16, 16, 27, 8, 28, 35, 29, 74,
+ 30, 27, 8, 28, 45, 29, 40, 30, 36, 35,
+ 41, 59, 40, 63, 92, 46, 41, 91, 64, 90,
+ 36, 93, 93, 89, 88, 87, 86, 81, 26, 26,
+ 26, 26, 34, 34, 34, 34, 39, 39, 39, 39,
+ 43, 43, 43, 44, 44, 70, 70, 85, 84, 83,
+ 82, 80, 79, 78, 77, 76, 75, 74, 73, 72,
+
+ 71, 33, 69, 68, 67, 66, 65, 62, 61, 60,
+ 42, 58, 57, 32, 31, 56, 55, 33, 31, 54,
+ 53, 52, 51, 50, 49, 48, 47, 42, 38, 37,
+ 33, 32, 31, 94, 5, 94, 94, 94, 94, 94,
+ 94, 94, 94, 94, 94, 94, 94, 94, 94, 94,
+ 94, 94, 94, 94, 94, 94, 94, 94, 94, 94,
+ 94, 94, 94, 94, 94, 94, 94, 94, 94
+ } ;
+
+static yyconst flex_int16_t yy_chk[170] =
+ { 0,
+ 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, 3, 3, 10, 3, 74,
+ 3, 4, 4, 4, 17, 4, 14, 4, 10, 34,
+ 14, 100, 39, 49, 90, 17, 39, 86, 49, 85,
+ 34, 91, 91, 84, 83, 82, 81, 74, 95, 95,
+ 95, 95, 96, 96, 96, 96, 97, 97, 97, 97,
+ 98, 98, 98, 99, 99, 101, 101, 80, 77, 76,
+ 75, 72, 71, 69, 68, 67, 65, 64, 63, 61,
+
+ 60, 57, 54, 53, 52, 51, 50, 47, 46, 45,
+ 43, 40, 33, 32, 31, 30, 29, 28, 27, 25,
+ 24, 23, 22, 21, 20, 19, 18, 15, 13, 11,
+ 9, 8, 7, 5, 94, 94, 94, 94, 94, 94,
+ 94, 94, 94, 94, 94, 94, 94, 94, 94, 94,
+ 94, 94, 94, 94, 94, 94, 94, 94, 94, 94,
+ 94, 94, 94, 94, 94, 94, 94, 94, 94
+ } ;
+
+/* Table of booleans, true if rule could match eol. */
+static yyconst flex_int32_t yy_rule_can_match_eol[30] =
+ { 0,
+0, 1, 1, 1, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, };
+
+/* The intent behind this definition is that it'll catch
+ * any uses of REJECT which flex missed.
+ */
+#define REJECT reject_used_but_not_detected
+#define yymore() yymore_used_but_not_detected
+#define YY_MORE_ADJ 0
+#define YY_RESTORE_YY_MORE_OFFSET
+#line 1 "lexer.l"
+/* Scanner for config specs -*- C -*- */
+#define YY_NO_INPUT 1
+
+#line 16 "lexer.l"
+#include "syntax.h"
+#include "errcode.h"
+
+typedef struct info YYLTYPE;
+#define YYLTYPE_IS_DECLARED 1
+
+#include "parser.h"
+
+/* Advance of NUM lines. */
+# define LOCATION_LINES(Loc, Num) \
+ (Loc).last_column = 0; \
+ (Loc).last_line += Num;
+
+/* Restart: move the first cursor to the last position. */
+# define LOCATION_STEP(Loc) \
+ (Loc).first_column = (Loc).last_column; \
+ (Loc).first_line = (Loc).last_line;
+
+/* The lack of reference counting for filename is intentional */
+#define YY_USER_ACTION \
+ do { \
+ yylloc->last_column += yyleng; \
+ yylloc->filename = augl_get_info(yyscanner)->filename; \
+ yylloc->error = augl_get_info(yyscanner)->error; \
+ } while(0);
+
+#define YY_USER_INIT LOCATION_STEP(*yylloc)
+
+#define YY_EXTRA_TYPE struct state *
+
+int augl_init_lexer(struct state *state, yyscan_t * scanner);
+void augl_close_lexer(yyscan_t *scanner);
+struct info *augl_get_info(yyscan_t yyscanner);
+
+static void loc_update(YYLTYPE *yylloc, const char *s, int len) {
+ for (int i=0; i < len; i++) {
+ if (s[i] == '\n') {
+ LOCATION_LINES(*yylloc, 1);
+ }
+ }
+}
+
+static char *regexp_literal(const char *s, int len) {
+ char *u = unescape(s, len, RX_ESCAPES);
+
+ if (u == NULL)
+ return NULL;
+
+ size_t u_len = strlen(u);
+ regexp_c_locale(&u, &u_len);
+
+ return u;
+}
+
+#line 584 "lexer.c"
+
+#define INITIAL 0
+#define COMMENT 1
+
+#ifndef YY_NO_UNISTD_H
+/* Special case for "unistd.h", since it is non-ANSI. We include it way
+ * down here because we want the user's section 1 to have been scanned first.
+ * The user has a chance to override it with an option.
+ */
+#include
+#endif
+
+#ifndef YY_EXTRA_TYPE
+#define YY_EXTRA_TYPE void *
+#endif
+
+/* Holds the entire state of the reentrant scanner. */
+struct yyguts_t
+ {
+
+ /* User-defined. Not touched by flex. */
+ YY_EXTRA_TYPE yyextra_r;
+
+ /* The rest are the same as the globals declared in the non-reentrant scanner. */
+ FILE *yyin_r, *yyout_r;
+ size_t yy_buffer_stack_top; /**< index of top of stack. */
+ size_t yy_buffer_stack_max; /**< capacity of stack. */
+ YY_BUFFER_STATE * yy_buffer_stack; /**< Stack as an array. */
+ char yy_hold_char;
+ int yy_n_chars;
+ int yyleng_r;
+ char *yy_c_buf_p;
+ int yy_init;
+ int yy_start;
+ int yy_did_buffer_switch_on_eof;
+ int yy_start_stack_ptr;
+ int yy_start_stack_depth;
+ int *yy_start_stack;
+ yy_state_type yy_last_accepting_state;
+ char* yy_last_accepting_cpos;
+
+ int yylineno_r;
+ int yy_flex_debug_r;
+
+ char *yytext_r;
+ int yy_more_flag;
+ int yy_more_len;
+
+ YYSTYPE * yylval_r;
+
+ YYLTYPE * yylloc_r;
+
+ }; /* end struct yyguts_t */
+
+static int yy_init_globals (yyscan_t yyscanner );
+
+ /* This must go here because YYSTYPE and YYLTYPE are included
+ * from bison output in section 1.*/
+ # define yylval yyg->yylval_r
+
+ # define yylloc yyg->yylloc_r
+
+int augl_lex_init (yyscan_t* scanner);
+
+int augl_lex_init_extra (YY_EXTRA_TYPE user_defined,yyscan_t* scanner);
+
+/* Accessor methods to globals.
+ These are made visible to non-reentrant scanners for convenience. */
+
+int augl_lex_destroy (yyscan_t yyscanner );
+
+int augl_get_debug (yyscan_t yyscanner );
+
+void augl_set_debug (int debug_flag ,yyscan_t yyscanner );
+
+YY_EXTRA_TYPE augl_get_extra (yyscan_t yyscanner );
+
+void augl_set_extra (YY_EXTRA_TYPE user_defined ,yyscan_t yyscanner );
+
+FILE *augl_get_in (yyscan_t yyscanner );
+
+void augl_set_in (FILE * in_str ,yyscan_t yyscanner );
+
+FILE *augl_get_out (yyscan_t yyscanner );
+
+void augl_set_out (FILE * out_str ,yyscan_t yyscanner );
+
+int augl_get_leng (yyscan_t yyscanner );
+
+char *augl_get_text (yyscan_t yyscanner );
+
+int augl_get_lineno (yyscan_t yyscanner );
+
+void augl_set_lineno (int line_number ,yyscan_t yyscanner );
+
+YYSTYPE * augl_get_lval (yyscan_t yyscanner );
+
+void augl_set_lval (YYSTYPE * yylval_param ,yyscan_t yyscanner );
+
+ YYLTYPE *augl_get_lloc (yyscan_t yyscanner );
+
+ void augl_set_lloc (YYLTYPE * yylloc_param ,yyscan_t yyscanner );
+
+/* Macros after this point can all be overridden by user definitions in
+ * section 1.
+ */
+
+#ifndef YY_SKIP_YYWRAP
+#ifdef __cplusplus
+extern "C" int augl_wrap (yyscan_t yyscanner );
+#else
+extern int augl_wrap (yyscan_t yyscanner );
+#endif
+#endif
+
+#ifndef yytext_ptr
+static void yy_flex_strncpy (char *,yyconst char *,int ,yyscan_t yyscanner);
+#endif
+
+#ifdef YY_NEED_STRLEN
+static int yy_flex_strlen (yyconst char * ,yyscan_t yyscanner);
+#endif
+
+#ifndef YY_NO_INPUT
+
+#ifdef __cplusplus
+static int yyinput (yyscan_t yyscanner );
+#else
+static int input (yyscan_t yyscanner );
+#endif
+
+#endif
+
+/* Amount of stuff to slurp up with each read. */
+#ifndef YY_READ_BUF_SIZE
+#define YY_READ_BUF_SIZE 8192
+#endif
+
+/* Copy whatever the last rule matched to the standard output. */
+#ifndef ECHO
+/* This used to be an fputs(), but since the string might contain NUL's,
+ * we now use fwrite().
+ */
+#define ECHO do { if (fwrite( yytext, yyleng, 1, yyout )) {} } while (0)
+#endif
+
+/* Gets input and stuffs it into "buf". number of characters read, or YY_NULL,
+ * is returned in "result".
+ */
+#ifndef YY_INPUT
+#define YY_INPUT(buf,result,max_size) \
+ if ( YY_CURRENT_BUFFER_LVALUE->yy_is_interactive ) \
+ { \
+ int c = '*'; \
+ unsigned n; \
+ for ( n = 0; n < max_size && \
+ (c = getc( yyin )) != EOF && c != '\n'; ++n ) \
+ buf[n] = (char) c; \
+ if ( c == '\n' ) \
+ buf[n++] = (char) c; \
+ if ( c == EOF && ferror( yyin ) ) \
+ YY_FATAL_ERROR( "input in flex scanner failed" ); \
+ result = n; \
+ } \
+ else \
+ { \
+ errno=0; \
+ while ( (result = fread(buf, 1, max_size, yyin))==0 && ferror(yyin)) \
+ { \
+ if( errno != EINTR) \
+ { \
+ YY_FATAL_ERROR( "input in flex scanner failed" ); \
+ break; \
+ } \
+ errno=0; \
+ clearerr(yyin); \
+ } \
+ }\
+\
+
+#endif
+
+/* No semi-colon after return; correct usage is to write "yyterminate();" -
+ * we don't want an extra ';' after the "return" because that will cause
+ * some compilers to complain about unreachable statements.
+ */
+#ifndef yyterminate
+#define yyterminate() return YY_NULL
+#endif
+
+/* Number of entries by which start-condition stack grows. */
+#ifndef YY_START_STACK_INCR
+#define YY_START_STACK_INCR 25
+#endif
+
+/* Report a fatal error. */
+#ifndef YY_FATAL_ERROR
+#define YY_FATAL_ERROR(msg) yy_fatal_error( msg , yyscanner)
+#endif
+
+/* end tables serialization structures and prototypes */
+
+/* Default declaration of generated scanner - a define so the user can
+ * easily add parameters.
+ */
+#ifndef YY_DECL
+#define YY_DECL_IS_OURS 1
+
+extern int augl_lex \
+ (YYSTYPE * yylval_param,YYLTYPE * yylloc_param ,yyscan_t yyscanner);
+
+#define YY_DECL int augl_lex \
+ (YYSTYPE * yylval_param, YYLTYPE * yylloc_param , yyscan_t yyscanner)
+#endif /* !YY_DECL */
+
+/* Code executed at the beginning of each rule, after yytext and yyleng
+ * have been set up.
+ */
+#ifndef YY_USER_ACTION
+#define YY_USER_ACTION
+#endif
+
+/* Code executed at the end of each rule. */
+#ifndef YY_BREAK
+#define YY_BREAK break;
+#endif
+
+#define YY_RULE_SETUP \
+ YY_USER_ACTION
+
+/** The main scanner function which does all the work.
+ */
+YY_DECL
+{
+ register yy_state_type yy_current_state;
+ register char *yy_cp, *yy_bp;
+ register int yy_act;
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+
+#line 81 "lexer.l"
+
+#line 826 "lexer.c"
+
+ yylval = yylval_param;
+
+ yylloc = yylloc_param;
+
+ if ( !yyg->yy_init )
+ {
+ yyg->yy_init = 1;
+
+#ifdef YY_USER_INIT
+ YY_USER_INIT;
+#endif
+
+ if ( ! yyg->yy_start )
+ yyg->yy_start = 1; /* first start state */
+
+ if ( ! yyin )
+ yyin = stdin;
+
+ if ( ! yyout )
+ yyout = stdout;
+
+ if ( ! YY_CURRENT_BUFFER ) {
+ augl_ensure_buffer_stack (yyscanner);
+ YY_CURRENT_BUFFER_LVALUE =
+ augl__create_buffer(yyin,YY_BUF_SIZE ,yyscanner);
+ }
+
+ augl__load_buffer_state(yyscanner );
+ }
+
+ while ( 1 ) /* loops until end-of-file is reached */
+ {
+ yy_cp = yyg->yy_c_buf_p;
+
+ /* Support of yytext. */
+ *yy_cp = yyg->yy_hold_char;
+
+ /* yy_bp points to the position in yy_ch_buf of the start of
+ * the current run.
+ */
+ yy_bp = yy_cp;
+
+ yy_current_state = yyg->yy_start;
+yy_match:
+ do
+ {
+ register YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)];
+ if ( yy_accept[yy_current_state] )
+ {
+ yyg->yy_last_accepting_state = yy_current_state;
+ yyg->yy_last_accepting_cpos = yy_cp;
+ }
+ while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
+ {
+ yy_current_state = (int) yy_def[yy_current_state];
+ if ( yy_current_state >= 95 )
+ yy_c = yy_meta[(unsigned int) yy_c];
+ }
+ yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
+ ++yy_cp;
+ }
+ while ( yy_current_state != 94 );
+ yy_cp = yyg->yy_last_accepting_cpos;
+ yy_current_state = yyg->yy_last_accepting_state;
+
+yy_find_action:
+ yy_act = yy_accept[yy_current_state];
+
+ YY_DO_BEFORE_ACTION;
+
+ if ( yy_act != YY_END_OF_BUFFER && yy_rule_can_match_eol[yy_act] )
+ {
+ int yyl;
+ for ( yyl = 0; yyl < yyleng; ++yyl )
+ if ( yytext[yyl] == '\n' )
+
+ do{ yylineno++;
+ yycolumn=0;
+ }while(0)
+;
+ }
+
+do_action: /* This label is used only to access EOF actions. */
+
+ switch ( yy_act )
+ { /* beginning of action switch */
+ case 0: /* must back up */
+ /* undo the effects of YY_DO_BEFORE_ACTION */
+ *yy_cp = yyg->yy_hold_char;
+ yy_cp = yyg->yy_last_accepting_cpos;
+ yy_current_state = yyg->yy_last_accepting_state;
+ goto yy_find_action;
+
+case 1:
+YY_RULE_SETUP
+#line 84 "lexer.l"
+LOCATION_STEP(*yylloc);
+ YY_BREAK
+case 2:
+/* rule 2 can match eol */
+YY_RULE_SETUP
+#line 85 "lexer.l"
+LOCATION_LINES(*yylloc, yyleng); LOCATION_STEP(*yylloc);
+ YY_BREAK
+case 3:
+/* rule 3 can match eol */
+YY_RULE_SETUP
+#line 86 "lexer.l"
+LOCATION_LINES(*yylloc, yyleng/2); LOCATION_STEP(*yylloc);
+ YY_BREAK
+
+
+
+case 4:
+/* rule 4 can match eol */
+YY_RULE_SETUP
+#line 91 "lexer.l"
+{
+ loc_update(yylloc, yytext, yyleng);
+ yylval->string = unescape(yytext+1, yyleng-2, STR_ESCAPES);
+ return DQUOTED;
+ }
+ YY_BREAK
+case 5:
+/* rule 5 can match eol */
+YY_RULE_SETUP
+#line 97 "lexer.l"
+{
+ loc_update(yylloc, yytext, yyleng);
+ yylval->regexp.nocase = 1;
+ yylval->regexp.pattern = regexp_literal(yytext+1, yyleng-3);
+ return REGEXP;
+ }
+ YY_BREAK
+case 6:
+/* rule 6 can match eol */
+YY_RULE_SETUP
+#line 104 "lexer.l"
+{
+ loc_update(yylloc, yytext, yyleng);
+ yylval->regexp.nocase = 0;
+ yylval->regexp.pattern = regexp_literal(yytext+1, yyleng-2);
+ return REGEXP;
+ }
+ YY_BREAK
+case 7:
+YY_RULE_SETUP
+#line 111 "lexer.l"
+return yytext[0];
+ YY_BREAK
+case 8:
+YY_RULE_SETUP
+#line 113 "lexer.l"
+return KW_MODULE;
+ YY_BREAK
+case 9:
+/* rule 9 can match eol */
+*yy_cp = yyg->yy_hold_char; /* undo effects of setting up yytext */
+yyg->yy_c_buf_p = yy_cp -= 1;
+YY_DO_BEFORE_ACTION; /* set up yytext again */
+YY_RULE_SETUP
+#line 115 "lexer.l"
+return KW_LET_REC;
+ YY_BREAK
+case 10:
+YY_RULE_SETUP
+#line 117 "lexer.l"
+return KW_LET;
+ YY_BREAK
+case 11:
+YY_RULE_SETUP
+#line 118 "lexer.l"
+return KW_STRING;
+ YY_BREAK
+case 12:
+YY_RULE_SETUP
+#line 119 "lexer.l"
+return KW_REGEXP;
+ YY_BREAK
+case 13:
+YY_RULE_SETUP
+#line 120 "lexer.l"
+return KW_LENS;
+ YY_BREAK
+case 14:
+YY_RULE_SETUP
+#line 121 "lexer.l"
+return KW_IN;
+ YY_BREAK
+case 15:
+YY_RULE_SETUP
+#line 122 "lexer.l"
+return KW_AUTOLOAD;
+ YY_BREAK
+/* tests */
+case 16:
+YY_RULE_SETUP
+#line 125 "lexer.l"
+return KW_TEST;
+ YY_BREAK
+case 17:
+YY_RULE_SETUP
+#line 126 "lexer.l"
+return KW_GET;
+ YY_BREAK
+case 18:
+YY_RULE_SETUP
+#line 127 "lexer.l"
+return KW_PUT;
+ YY_BREAK
+case 19:
+YY_RULE_SETUP
+#line 128 "lexer.l"
+return KW_AFTER;
+ YY_BREAK
+case 20:
+YY_RULE_SETUP
+#line 130 "lexer.l"
+return ARROW;
+ YY_BREAK
+case 21:
+YY_RULE_SETUP
+#line 132 "lexer.l"
+{
+ yylval->string = strndup(yytext, yyleng);
+ return QIDENT;
+ }
+ YY_BREAK
+case 22:
+YY_RULE_SETUP
+#line 136 "lexer.l"
+{
+ yylval->string = strndup(yytext, yyleng);
+ return LIDENT;
+ }
+ YY_BREAK
+case 23:
+YY_RULE_SETUP
+#line 140 "lexer.l"
+{
+ yylval->string = strndup(yytext, yyleng);
+ return UIDENT;
+ }
+ YY_BREAK
+case 24:
+YY_RULE_SETUP
+#line 144 "lexer.l"
+{
+ augl_get_extra(yyscanner)->comment_depth = 1;
+ BEGIN(COMMENT);
+ }
+ YY_BREAK
+case 25:
+YY_RULE_SETUP
+#line 148 "lexer.l"
+{
+ report_error(augl_get_info(yyscanner)->error, AUG_ESYNTAX,
+ "%s:%d:%d: Unexpected character %c",
+ augl_get_info(yyscanner)->filename->str,
+ yylineno, yylloc->first_column, yytext[0]);
+ }
+ YY_BREAK
+case YY_STATE_EOF(INITIAL):
+#line 155 "lexer.l"
+{
+ augl_close_lexer(yyscanner);
+ yyterminate();
+ }
+ YY_BREAK
+
+
+
+case 26:
+YY_RULE_SETUP
+#line 164 "lexer.l"
+{
+ augl_get_extra(yyscanner)->comment_depth += 1;
+ }
+ YY_BREAK
+case 27:
+YY_RULE_SETUP
+#line 167 "lexer.l"
+{
+ augl_get_extra(yyscanner)->comment_depth -= 1;
+ if (augl_get_extra(yyscanner)->comment_depth == 0)
+ BEGIN(INITIAL);
+ }
+ YY_BREAK
+case 28:
+YY_RULE_SETUP
+#line 172 "lexer.l"
+/* Skip */;
+ YY_BREAK
+case YY_STATE_EOF(COMMENT):
+#line 173 "lexer.l"
+{
+ report_error(augl_get_info(yyscanner)->error, AUG_ESYNTAX,
+ "%s:%d:%d: Missing *)",
+ augl_get_info(yyscanner)->filename->str,
+ yylineno, yylloc->first_column);
+ augl_close_lexer(yyscanner);
+ yyterminate();
+ }
+ YY_BREAK
+
+case 29:
+YY_RULE_SETUP
+#line 182 "lexer.l"
+YY_FATAL_ERROR( "flex scanner jammed" );
+ YY_BREAK
+#line 1138 "lexer.c"
+
+ case YY_END_OF_BUFFER:
+ {
+ /* Amount of text matched not including the EOB char. */
+ int yy_amount_of_matched_text = (int) (yy_cp - yyg->yytext_ptr) - 1;
+
+ /* Undo the effects of YY_DO_BEFORE_ACTION. */
+ *yy_cp = yyg->yy_hold_char;
+ YY_RESTORE_YY_MORE_OFFSET
+
+ if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_NEW )
+ {
+ /* We're scanning a new file or input source. It's
+ * possible that this happened because the user
+ * just pointed yyin at a new source and called
+ * augl_lex(). If so, then we have to assure
+ * consistency between YY_CURRENT_BUFFER and our
+ * globals. Here is the right place to do so, because
+ * this is the first action (other than possibly a
+ * back-up) that will match for the new input source.
+ */
+ yyg->yy_n_chars = YY_CURRENT_BUFFER_LVALUE->yy_n_chars;
+ YY_CURRENT_BUFFER_LVALUE->yy_input_file = yyin;
+ YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = YY_BUFFER_NORMAL;
+ }
+
+ /* Note that here we test for yy_c_buf_p "<=" to the position
+ * of the first EOB in the buffer, since yy_c_buf_p will
+ * already have been incremented past the NUL character
+ * (since all states make transitions on EOB to the
+ * end-of-buffer state). Contrast this with the test
+ * in input().
+ */
+ if ( yyg->yy_c_buf_p <= &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars] )
+ { /* This was really a NUL. */
+ yy_state_type yy_next_state;
+
+ yyg->yy_c_buf_p = yyg->yytext_ptr + yy_amount_of_matched_text;
+
+ yy_current_state = yy_get_previous_state( yyscanner );
+
+ /* Okay, we're now positioned to make the NUL
+ * transition. We couldn't have
+ * yy_get_previous_state() go ahead and do it
+ * for us because it doesn't know how to deal
+ * with the possibility of jamming (and we don't
+ * want to build jamming into it because then it
+ * will run more slowly).
+ */
+
+ yy_next_state = yy_try_NUL_trans( yy_current_state , yyscanner);
+
+ yy_bp = yyg->yytext_ptr + YY_MORE_ADJ;
+
+ if ( yy_next_state )
+ {
+ /* Consume the NUL. */
+ yy_cp = ++yyg->yy_c_buf_p;
+ yy_current_state = yy_next_state;
+ goto yy_match;
+ }
+
+ else
+ {
+ yy_cp = yyg->yy_last_accepting_cpos;
+ yy_current_state = yyg->yy_last_accepting_state;
+ goto yy_find_action;
+ }
+ }
+
+ else switch ( yy_get_next_buffer( yyscanner ) )
+ {
+ case EOB_ACT_END_OF_FILE:
+ {
+ yyg->yy_did_buffer_switch_on_eof = 0;
+
+ if ( augl_wrap(yyscanner ) )
+ {
+ /* Note: because we've taken care in
+ * yy_get_next_buffer() to have set up
+ * yytext, we can now set up
+ * yy_c_buf_p so that if some total
+ * hoser (like flex itself) wants to
+ * call the scanner after we return the
+ * YY_NULL, it'll still work - another
+ * YY_NULL will get returned.
+ */
+ yyg->yy_c_buf_p = yyg->yytext_ptr + YY_MORE_ADJ;
+
+ yy_act = YY_STATE_EOF(YY_START);
+ goto do_action;
+ }
+
+ else
+ {
+ if ( ! yyg->yy_did_buffer_switch_on_eof )
+ YY_NEW_FILE;
+ }
+ break;
+ }
+
+ case EOB_ACT_CONTINUE_SCAN:
+ yyg->yy_c_buf_p =
+ yyg->yytext_ptr + yy_amount_of_matched_text;
+
+ yy_current_state = yy_get_previous_state( yyscanner );
+
+ yy_cp = yyg->yy_c_buf_p;
+ yy_bp = yyg->yytext_ptr + YY_MORE_ADJ;
+ goto yy_match;
+
+ case EOB_ACT_LAST_MATCH:
+ yyg->yy_c_buf_p =
+ &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars];
+
+ yy_current_state = yy_get_previous_state( yyscanner );
+
+ yy_cp = yyg->yy_c_buf_p;
+ yy_bp = yyg->yytext_ptr + YY_MORE_ADJ;
+ goto yy_find_action;
+ }
+ break;
+ }
+
+ default:
+ YY_FATAL_ERROR(
+ "fatal flex scanner internal error--no action found" );
+ } /* end of action switch */
+ } /* end of scanning one token */
+} /* end of augl_lex */
+
+/* yy_get_next_buffer - try to read in a new buffer
+ *
+ * Returns a code representing an action:
+ * EOB_ACT_LAST_MATCH -
+ * EOB_ACT_CONTINUE_SCAN - continue scanning from current position
+ * EOB_ACT_END_OF_FILE - end of file
+ */
+static int yy_get_next_buffer (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ register char *dest = YY_CURRENT_BUFFER_LVALUE->yy_ch_buf;
+ register char *source = yyg->yytext_ptr;
+ register int number_to_move, i;
+ int ret_val;
+
+ if ( yyg->yy_c_buf_p > &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars + 1] )
+ YY_FATAL_ERROR(
+ "fatal flex scanner internal error--end of buffer missed" );
+
+ if ( YY_CURRENT_BUFFER_LVALUE->yy_fill_buffer == 0 )
+ { /* Don't try to fill the buffer, so this is an EOF. */
+ if ( yyg->yy_c_buf_p - yyg->yytext_ptr - YY_MORE_ADJ == 1 )
+ {
+ /* We matched a single character, the EOB, so
+ * treat this as a final EOF.
+ */
+ return EOB_ACT_END_OF_FILE;
+ }
+
+ else
+ {
+ /* We matched some text prior to the EOB, first
+ * process it.
+ */
+ return EOB_ACT_LAST_MATCH;
+ }
+ }
+
+ /* Try to read more data. */
+
+ /* First move last chars to start of buffer. */
+ number_to_move = (int) (yyg->yy_c_buf_p - yyg->yytext_ptr) - 1;
+
+ for ( i = 0; i < number_to_move; ++i )
+ *(dest++) = *(source++);
+
+ if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_EOF_PENDING )
+ /* don't do the read, it's not guaranteed to return an EOF,
+ * just force an EOF
+ */
+ YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars = 0;
+
+ else
+ {
+ int num_to_read =
+ YY_CURRENT_BUFFER_LVALUE->yy_buf_size - number_to_move - 1;
+
+ while ( num_to_read <= 0 )
+ { /* Not enough room in the buffer - grow it. */
+
+ /* just a shorter name for the current buffer */
+ YY_BUFFER_STATE b = YY_CURRENT_BUFFER;
+
+ int yy_c_buf_p_offset =
+ (int) (yyg->yy_c_buf_p - b->yy_ch_buf);
+
+ if ( b->yy_is_our_buffer )
+ {
+ int new_size = b->yy_buf_size * 2;
+
+ if ( new_size <= 0 )
+ b->yy_buf_size += b->yy_buf_size / 8;
+ else
+ b->yy_buf_size *= 2;
+
+ b->yy_ch_buf = (char *)
+ /* Include room in for 2 EOB chars. */
+ augl_realloc((void *) b->yy_ch_buf,b->yy_buf_size + 2 ,yyscanner );
+ }
+ else
+ /* Can't grow it, we don't own it. */
+ b->yy_ch_buf = 0;
+
+ if ( ! b->yy_ch_buf )
+ YY_FATAL_ERROR(
+ "fatal error - scanner input buffer overflow" );
+
+ yyg->yy_c_buf_p = &b->yy_ch_buf[yy_c_buf_p_offset];
+
+ num_to_read = YY_CURRENT_BUFFER_LVALUE->yy_buf_size -
+ number_to_move - 1;
+
+ }
+
+ if ( num_to_read > YY_READ_BUF_SIZE )
+ num_to_read = YY_READ_BUF_SIZE;
+
+ /* Read in more data. */
+ YY_INPUT( (&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move]),
+ yyg->yy_n_chars, (size_t) num_to_read );
+
+ YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars;
+ }
+
+ if ( yyg->yy_n_chars == 0 )
+ {
+ if ( number_to_move == YY_MORE_ADJ )
+ {
+ ret_val = EOB_ACT_END_OF_FILE;
+ augl_restart(yyin ,yyscanner);
+ }
+
+ else
+ {
+ ret_val = EOB_ACT_LAST_MATCH;
+ YY_CURRENT_BUFFER_LVALUE->yy_buffer_status =
+ YY_BUFFER_EOF_PENDING;
+ }
+ }
+
+ else
+ ret_val = EOB_ACT_CONTINUE_SCAN;
+
+ if ((yy_size_t) (yyg->yy_n_chars + number_to_move) > YY_CURRENT_BUFFER_LVALUE->yy_buf_size) {
+ /* Extend the array by 50%, plus the number we really need. */
+ yy_size_t new_size = yyg->yy_n_chars + number_to_move + (yyg->yy_n_chars >> 1);
+ YY_CURRENT_BUFFER_LVALUE->yy_ch_buf = (char *) augl_realloc((void *) YY_CURRENT_BUFFER_LVALUE->yy_ch_buf,new_size ,yyscanner );
+ if ( ! YY_CURRENT_BUFFER_LVALUE->yy_ch_buf )
+ YY_FATAL_ERROR( "out of dynamic memory in yy_get_next_buffer()" );
+ }
+
+ yyg->yy_n_chars += number_to_move;
+ YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars] = YY_END_OF_BUFFER_CHAR;
+ YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars + 1] = YY_END_OF_BUFFER_CHAR;
+
+ yyg->yytext_ptr = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[0];
+
+ return ret_val;
+}
+
+/* yy_get_previous_state - get the state just before the EOB char was reached */
+
+ static yy_state_type yy_get_previous_state (yyscan_t yyscanner)
+{
+ register yy_state_type yy_current_state;
+ register char *yy_cp;
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+
+ yy_current_state = yyg->yy_start;
+
+ for ( yy_cp = yyg->yytext_ptr + YY_MORE_ADJ; yy_cp < yyg->yy_c_buf_p; ++yy_cp )
+ {
+ register YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1);
+ if ( yy_accept[yy_current_state] )
+ {
+ yyg->yy_last_accepting_state = yy_current_state;
+ yyg->yy_last_accepting_cpos = yy_cp;
+ }
+ while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
+ {
+ yy_current_state = (int) yy_def[yy_current_state];
+ if ( yy_current_state >= 95 )
+ yy_c = yy_meta[(unsigned int) yy_c];
+ }
+ yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
+ }
+
+ return yy_current_state;
+}
+
+/* yy_try_NUL_trans - try to make a transition on the NUL character
+ *
+ * synopsis
+ * next_state = yy_try_NUL_trans( current_state );
+ */
+ static yy_state_type yy_try_NUL_trans (yy_state_type yy_current_state , yyscan_t yyscanner)
+{
+ register int yy_is_jam;
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; /* This var may be unused depending upon options. */
+ register char *yy_cp = yyg->yy_c_buf_p;
+
+ register YY_CHAR yy_c = 1;
+ if ( yy_accept[yy_current_state] )
+ {
+ yyg->yy_last_accepting_state = yy_current_state;
+ yyg->yy_last_accepting_cpos = yy_cp;
+ }
+ while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
+ {
+ yy_current_state = (int) yy_def[yy_current_state];
+ if ( yy_current_state >= 95 )
+ yy_c = yy_meta[(unsigned int) yy_c];
+ }
+ yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
+ yy_is_jam = (yy_current_state == 94);
+
+ return yy_is_jam ? 0 : yy_current_state;
+}
+
+#ifndef YY_NO_INPUT
+#ifdef __cplusplus
+ static int yyinput (yyscan_t yyscanner)
+#else
+ static int input (yyscan_t yyscanner)
+#endif
+
+{
+ int c;
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+
+ *yyg->yy_c_buf_p = yyg->yy_hold_char;
+
+ if ( *yyg->yy_c_buf_p == YY_END_OF_BUFFER_CHAR )
+ {
+ /* yy_c_buf_p now points to the character we want to return.
+ * If this occurs *before* the EOB characters, then it's a
+ * valid NUL; if not, then we've hit the end of the buffer.
+ */
+ if ( yyg->yy_c_buf_p < &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars] )
+ /* This was really a NUL. */
+ *yyg->yy_c_buf_p = '\0';
+
+ else
+ { /* need more input */
+ int offset = yyg->yy_c_buf_p - yyg->yytext_ptr;
+ ++yyg->yy_c_buf_p;
+
+ switch ( yy_get_next_buffer( yyscanner ) )
+ {
+ case EOB_ACT_LAST_MATCH:
+ /* This happens because yy_g_n_b()
+ * sees that we've accumulated a
+ * token and flags that we need to
+ * try matching the token before
+ * proceeding. But for input(),
+ * there's no matching to consider.
+ * So convert the EOB_ACT_LAST_MATCH
+ * to EOB_ACT_END_OF_FILE.
+ */
+
+ /* Reset buffer status. */
+ augl_restart(yyin ,yyscanner);
+
+ /*FALLTHROUGH*/
+
+ case EOB_ACT_END_OF_FILE:
+ {
+ if ( augl_wrap(yyscanner ) )
+ return EOF;
+
+ if ( ! yyg->yy_did_buffer_switch_on_eof )
+ YY_NEW_FILE;
+#ifdef __cplusplus
+ return yyinput(yyscanner);
+#else
+ return input(yyscanner);
+#endif
+ }
+
+ case EOB_ACT_CONTINUE_SCAN:
+ yyg->yy_c_buf_p = yyg->yytext_ptr + offset;
+ break;
+ }
+ }
+ }
+
+ c = *(unsigned char *) yyg->yy_c_buf_p; /* cast for 8-bit char's */
+ *yyg->yy_c_buf_p = '\0'; /* preserve yytext */
+ yyg->yy_hold_char = *++yyg->yy_c_buf_p;
+
+ if ( c == '\n' )
+
+ do{ yylineno++;
+ yycolumn=0;
+ }while(0)
+;
+
+ return c;
+}
+#endif /* ifndef YY_NO_INPUT */
+
+/** Immediately switch to a different input stream.
+ * @param input_file A readable stream.
+ * @param yyscanner The scanner object.
+ * @note This function does not reset the start condition to @c INITIAL .
+ */
+ void augl_restart (FILE * input_file , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+
+ if ( ! YY_CURRENT_BUFFER ){
+ augl_ensure_buffer_stack (yyscanner);
+ YY_CURRENT_BUFFER_LVALUE =
+ augl__create_buffer(yyin,YY_BUF_SIZE ,yyscanner);
+ }
+
+ augl__init_buffer(YY_CURRENT_BUFFER,input_file ,yyscanner);
+ augl__load_buffer_state(yyscanner );
+}
+
+/** Switch to a different input buffer.
+ * @param new_buffer The new input buffer.
+ * @param yyscanner The scanner object.
+ */
+ void augl__switch_to_buffer (YY_BUFFER_STATE new_buffer , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+
+ /* TODO. We should be able to replace this entire function body
+ * with
+ * augl_pop_buffer_state();
+ * augl_push_buffer_state(new_buffer);
+ */
+ augl_ensure_buffer_stack (yyscanner);
+ if ( YY_CURRENT_BUFFER == new_buffer )
+ return;
+
+ if ( YY_CURRENT_BUFFER )
+ {
+ /* Flush out information for old buffer. */
+ *yyg->yy_c_buf_p = yyg->yy_hold_char;
+ YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = yyg->yy_c_buf_p;
+ YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars;
+ }
+
+ YY_CURRENT_BUFFER_LVALUE = new_buffer;
+ augl__load_buffer_state(yyscanner );
+
+ /* We don't actually know whether we did this switch during
+ * EOF (augl_wrap()) processing, but the only time this flag
+ * is looked at is after augl_wrap() is called, so it's safe
+ * to go ahead and always set it.
+ */
+ yyg->yy_did_buffer_switch_on_eof = 1;
+}
+
+static void augl__load_buffer_state (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ yyg->yy_n_chars = YY_CURRENT_BUFFER_LVALUE->yy_n_chars;
+ yyg->yytext_ptr = yyg->yy_c_buf_p = YY_CURRENT_BUFFER_LVALUE->yy_buf_pos;
+ yyin = YY_CURRENT_BUFFER_LVALUE->yy_input_file;
+ yyg->yy_hold_char = *yyg->yy_c_buf_p;
+}
+
+/** Allocate and initialize an input buffer state.
+ * @param file A readable stream.
+ * @param size The character buffer size in bytes. When in doubt, use @c YY_BUF_SIZE.
+ * @param yyscanner The scanner object.
+ * @return the allocated buffer state.
+ */
+ YY_BUFFER_STATE augl__create_buffer (FILE * file, int size , yyscan_t yyscanner)
+{
+ YY_BUFFER_STATE b;
+
+ b = (YY_BUFFER_STATE) augl_alloc(sizeof( struct yy_buffer_state ) ,yyscanner );
+ if ( ! b )
+ YY_FATAL_ERROR( "out of dynamic memory in augl__create_buffer()" );
+
+ b->yy_buf_size = size;
+
+ /* yy_ch_buf has to be 2 characters longer than the size given because
+ * we need to put in 2 end-of-buffer characters.
+ */
+ b->yy_ch_buf = (char *) augl_alloc(b->yy_buf_size + 2 ,yyscanner );
+ if ( ! b->yy_ch_buf )
+ YY_FATAL_ERROR( "out of dynamic memory in augl__create_buffer()" );
+
+ b->yy_is_our_buffer = 1;
+
+ augl__init_buffer(b,file ,yyscanner);
+
+ return b;
+}
+
+/** Destroy the buffer.
+ * @param b a buffer created with augl__create_buffer()
+ * @param yyscanner The scanner object.
+ */
+ void augl__delete_buffer (YY_BUFFER_STATE b , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+
+ if ( ! b )
+ return;
+
+ if ( b == YY_CURRENT_BUFFER ) /* Not sure if we should pop here. */
+ YY_CURRENT_BUFFER_LVALUE = (YY_BUFFER_STATE) 0;
+
+ if ( b->yy_is_our_buffer )
+ augl_free((void *) b->yy_ch_buf ,yyscanner );
+
+ augl_free((void *) b ,yyscanner );
+}
+
+/* Initializes or reinitializes a buffer.
+ * This function is sometimes called more than once on the same buffer,
+ * such as during a augl_restart() or at EOF.
+ */
+ static void augl__init_buffer (YY_BUFFER_STATE b, FILE * file , yyscan_t yyscanner)
+
+{
+ int oerrno = errno;
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+
+ augl__flush_buffer(b ,yyscanner);
+
+ b->yy_input_file = file;
+ b->yy_fill_buffer = 1;
+
+ /* If b is the current buffer, then augl__init_buffer was _probably_
+ * called from augl_restart() or through yy_get_next_buffer.
+ * In that case, we don't want to reset the lineno or column.
+ */
+ if (b != YY_CURRENT_BUFFER){
+ b->yy_bs_lineno = 1;
+ b->yy_bs_column = 0;
+ }
+
+ b->yy_is_interactive = 0;
+
+ errno = oerrno;
+}
+
+/** Discard all buffered characters. On the next scan, YY_INPUT will be called.
+ * @param b the buffer state to be flushed, usually @c YY_CURRENT_BUFFER.
+ * @param yyscanner The scanner object.
+ */
+ void augl__flush_buffer (YY_BUFFER_STATE b , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ if ( ! b )
+ return;
+
+ b->yy_n_chars = 0;
+
+ /* We always need two end-of-buffer characters. The first causes
+ * a transition to the end-of-buffer state. The second causes
+ * a jam in that state.
+ */
+ b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR;
+ b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR;
+
+ b->yy_buf_pos = &b->yy_ch_buf[0];
+
+ b->yy_at_bol = 1;
+ b->yy_buffer_status = YY_BUFFER_NEW;
+
+ if ( b == YY_CURRENT_BUFFER )
+ augl__load_buffer_state(yyscanner );
+}
+
+/** Pushes the new state onto the stack. The new state becomes
+ * the current state. This function will allocate the stack
+ * if necessary.
+ * @param new_buffer The new state.
+ * @param yyscanner The scanner object.
+ */
+void augl_push_buffer_state (YY_BUFFER_STATE new_buffer , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ if (new_buffer == NULL)
+ return;
+
+ augl_ensure_buffer_stack(yyscanner);
+
+ /* This block is copied from augl__switch_to_buffer. */
+ if ( YY_CURRENT_BUFFER )
+ {
+ /* Flush out information for old buffer. */
+ *yyg->yy_c_buf_p = yyg->yy_hold_char;
+ YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = yyg->yy_c_buf_p;
+ YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars;
+ }
+
+ /* Only push if top exists. Otherwise, replace top. */
+ if (YY_CURRENT_BUFFER)
+ yyg->yy_buffer_stack_top++;
+ YY_CURRENT_BUFFER_LVALUE = new_buffer;
+
+ /* copied from augl__switch_to_buffer. */
+ augl__load_buffer_state(yyscanner );
+ yyg->yy_did_buffer_switch_on_eof = 1;
+}
+
+/** Removes and deletes the top of the stack, if present.
+ * The next element becomes the new top.
+ * @param yyscanner The scanner object.
+ */
+void augl_pop_buffer_state (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ if (!YY_CURRENT_BUFFER)
+ return;
+
+ augl__delete_buffer(YY_CURRENT_BUFFER ,yyscanner);
+ YY_CURRENT_BUFFER_LVALUE = NULL;
+ if (yyg->yy_buffer_stack_top > 0)
+ --yyg->yy_buffer_stack_top;
+
+ if (YY_CURRENT_BUFFER) {
+ augl__load_buffer_state(yyscanner );
+ yyg->yy_did_buffer_switch_on_eof = 1;
+ }
+}
+
+/* Allocates the stack if it does not exist.
+ * Guarantees space for at least one push.
+ */
+static void augl_ensure_buffer_stack (yyscan_t yyscanner)
+{
+ int num_to_alloc;
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+
+ if (!yyg->yy_buffer_stack) {
+
+ /* First allocation is just for 2 elements, since we don't know if this
+ * scanner will even need a stack. We use 2 instead of 1 to avoid an
+ * immediate realloc on the next call.
+ */
+ num_to_alloc = 1;
+ yyg->yy_buffer_stack = (struct yy_buffer_state**)augl_alloc
+ (num_to_alloc * sizeof(struct yy_buffer_state*)
+ , yyscanner);
+ if ( ! yyg->yy_buffer_stack )
+ YY_FATAL_ERROR( "out of dynamic memory in augl_ensure_buffer_stack()" );
+
+ memset(yyg->yy_buffer_stack, 0, num_to_alloc * sizeof(struct yy_buffer_state*));
+
+ yyg->yy_buffer_stack_max = num_to_alloc;
+ yyg->yy_buffer_stack_top = 0;
+ return;
+ }
+
+ if (yyg->yy_buffer_stack_top >= (yyg->yy_buffer_stack_max) - 1){
+
+ /* Increase the buffer to prepare for a possible push. */
+ int grow_size = 8 /* arbitrary grow size */;
+
+ num_to_alloc = yyg->yy_buffer_stack_max + grow_size;
+ yyg->yy_buffer_stack = (struct yy_buffer_state**)augl_realloc
+ (yyg->yy_buffer_stack,
+ num_to_alloc * sizeof(struct yy_buffer_state*)
+ , yyscanner);
+ if ( ! yyg->yy_buffer_stack )
+ YY_FATAL_ERROR( "out of dynamic memory in augl_ensure_buffer_stack()" );
+
+ /* zero only the new slots.*/
+ memset(yyg->yy_buffer_stack + yyg->yy_buffer_stack_max, 0, grow_size * sizeof(struct yy_buffer_state*));
+ yyg->yy_buffer_stack_max = num_to_alloc;
+ }
+}
+
+/** Setup the input buffer state to scan directly from a user-specified character buffer.
+ * @param base the character buffer
+ * @param size the size in bytes of the character buffer
+ * @param yyscanner The scanner object.
+ * @return the newly allocated buffer state object.
+ */
+YY_BUFFER_STATE augl__scan_buffer (char * base, yy_size_t size , yyscan_t yyscanner)
+{
+ YY_BUFFER_STATE b;
+
+ if ( size < 2 ||
+ base[size-2] != YY_END_OF_BUFFER_CHAR ||
+ base[size-1] != YY_END_OF_BUFFER_CHAR )
+ /* They forgot to leave room for the EOB's. */
+ return 0;
+
+ b = (YY_BUFFER_STATE) augl_alloc(sizeof( struct yy_buffer_state ) ,yyscanner );
+ if ( ! b )
+ YY_FATAL_ERROR( "out of dynamic memory in augl__scan_buffer()" );
+
+ b->yy_buf_size = size - 2; /* "- 2" to take care of EOB's */
+ b->yy_buf_pos = b->yy_ch_buf = base;
+ b->yy_is_our_buffer = 0;
+ b->yy_input_file = 0;
+ b->yy_n_chars = b->yy_buf_size;
+ b->yy_is_interactive = 0;
+ b->yy_at_bol = 1;
+ b->yy_fill_buffer = 0;
+ b->yy_buffer_status = YY_BUFFER_NEW;
+
+ augl__switch_to_buffer(b ,yyscanner );
+
+ return b;
+}
+
+/** Setup the input buffer state to scan a string. The next call to augl_lex() will
+ * scan from a @e copy of @a str.
+ * @param yystr a NUL-terminated string to scan
+ * @param yyscanner The scanner object.
+ * @return the newly allocated buffer state object.
+ * @note If you want to scan bytes that may contain NUL values, then use
+ * augl__scan_bytes() instead.
+ */
+YY_BUFFER_STATE augl__scan_string (yyconst char * yystr , yyscan_t yyscanner)
+{
+
+ return augl__scan_bytes(yystr,strlen(yystr) ,yyscanner);
+}
+
+/** Setup the input buffer state to scan the given bytes. The next call to augl_lex() will
+ * scan from a @e copy of @a bytes.
+ * @param bytes the byte buffer to scan
+ * @param len the number of bytes in the buffer pointed to by @a bytes.
+ * @param yyscanner The scanner object.
+ * @return the newly allocated buffer state object.
+ */
+YY_BUFFER_STATE augl__scan_bytes (yyconst char * yybytes, int _yybytes_len , yyscan_t yyscanner)
+{
+ YY_BUFFER_STATE b;
+ char *buf;
+ yy_size_t n;
+ int i;
+
+ /* Get memory for full buffer, including space for trailing EOB's. */
+ n = _yybytes_len + 2;
+ buf = (char *) augl_alloc(n ,yyscanner );
+ if ( ! buf )
+ YY_FATAL_ERROR( "out of dynamic memory in augl__scan_bytes()" );
+
+ for ( i = 0; i < _yybytes_len; ++i )
+ buf[i] = yybytes[i];
+
+ buf[_yybytes_len] = buf[_yybytes_len+1] = YY_END_OF_BUFFER_CHAR;
+
+ b = augl__scan_buffer(buf,n ,yyscanner);
+ if ( ! b )
+ YY_FATAL_ERROR( "bad buffer in augl__scan_bytes()" );
+
+ /* It's okay to grow etc. this buffer, and we should throw it
+ * away when we're done.
+ */
+ b->yy_is_our_buffer = 1;
+
+ return b;
+}
+
+#ifndef YY_EXIT_FAILURE
+#define YY_EXIT_FAILURE 2
+#endif
+
+static void yy_fatal_error (yyconst char* msg , yyscan_t yyscanner)
+{
+ (void) fprintf( stderr, "%s\n", msg );
+ exit( YY_EXIT_FAILURE );
+}
+
+/* Redefine yyless() so it works in section 3 code. */
+
+#undef yyless
+#define yyless(n) \
+ do \
+ { \
+ /* Undo effects of setting up yytext. */ \
+ int yyless_macro_arg = (n); \
+ YY_LESS_LINENO(yyless_macro_arg);\
+ yytext[yyleng] = yyg->yy_hold_char; \
+ yyg->yy_c_buf_p = yytext + yyless_macro_arg; \
+ yyg->yy_hold_char = *yyg->yy_c_buf_p; \
+ *yyg->yy_c_buf_p = '\0'; \
+ yyleng = yyless_macro_arg; \
+ } \
+ while ( 0 )
+
+/* Accessor methods (get/set functions) to struct members. */
+
+/** Get the user-defined data for this scanner.
+ * @param yyscanner The scanner object.
+ */
+YY_EXTRA_TYPE augl_get_extra (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ return yyextra;
+}
+
+/** Get the current line number.
+ * @param yyscanner The scanner object.
+ */
+int augl_get_lineno (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+
+ if (! YY_CURRENT_BUFFER)
+ return 0;
+
+ return yylineno;
+}
+
+/** Get the current column number.
+ * @param yyscanner The scanner object.
+ */
+int augl_get_column (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+
+ if (! YY_CURRENT_BUFFER)
+ return 0;
+
+ return yycolumn;
+}
+
+/** Get the input stream.
+ * @param yyscanner The scanner object.
+ */
+FILE *augl_get_in (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ return yyin;
+}
+
+/** Get the output stream.
+ * @param yyscanner The scanner object.
+ */
+FILE *augl_get_out (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ return yyout;
+}
+
+/** Get the length of the current token.
+ * @param yyscanner The scanner object.
+ */
+int augl_get_leng (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ return yyleng;
+}
+
+/** Get the current token.
+ * @param yyscanner The scanner object.
+ */
+
+char *augl_get_text (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ return yytext;
+}
+
+/** Set the user-defined data. This data is never touched by the scanner.
+ * @param user_defined The data to be associated with this scanner.
+ * @param yyscanner The scanner object.
+ */
+void augl_set_extra (YY_EXTRA_TYPE user_defined , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ yyextra = user_defined ;
+}
+
+/** Set the current line number.
+ * @param line_number
+ * @param yyscanner The scanner object.
+ */
+void augl_set_lineno (int line_number , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+
+ /* lineno is only valid if an input buffer exists. */
+ if (! YY_CURRENT_BUFFER )
+ yy_fatal_error( "augl_set_lineno called with no buffer" , yyscanner);
+
+ yylineno = line_number;
+}
+
+/** Set the current column.
+ * @param line_number
+ * @param yyscanner The scanner object.
+ */
+void augl_set_column (int column_no , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+
+ /* column is only valid if an input buffer exists. */
+ if (! YY_CURRENT_BUFFER )
+ yy_fatal_error( "augl_set_column called with no buffer" , yyscanner);
+
+ yycolumn = column_no;
+}
+
+/** Set the input stream. This does not discard the current
+ * input buffer.
+ * @param in_str A readable stream.
+ * @param yyscanner The scanner object.
+ * @see augl__switch_to_buffer
+ */
+void augl_set_in (FILE * in_str , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ yyin = in_str ;
+}
+
+void augl_set_out (FILE * out_str , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ yyout = out_str ;
+}
+
+int augl_get_debug (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ return yy_flex_debug;
+}
+
+void augl_set_debug (int bdebug , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ yy_flex_debug = bdebug ;
+}
+
+/* Accessor methods for yylval and yylloc */
+
+YYSTYPE * augl_get_lval (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ return yylval;
+}
+
+void augl_set_lval (YYSTYPE * yylval_param , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ yylval = yylval_param;
+}
+
+YYLTYPE *augl_get_lloc (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ return yylloc;
+}
+
+void augl_set_lloc (YYLTYPE * yylloc_param , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ yylloc = yylloc_param;
+}
+
+/* User-visible API */
+
+/* augl_lex_init is special because it creates the scanner itself, so it is
+ * the ONLY reentrant function that doesn't take the scanner as the last argument.
+ * That's why we explicitly handle the declaration, instead of using our macros.
+ */
+
+int augl_lex_init(yyscan_t* ptr_yy_globals)
+
+{
+ if (ptr_yy_globals == NULL){
+ errno = EINVAL;
+ return 1;
+ }
+
+ *ptr_yy_globals = (yyscan_t) augl_alloc ( sizeof( struct yyguts_t ), NULL );
+
+ if (*ptr_yy_globals == NULL){
+ errno = ENOMEM;
+ return 1;
+ }
+
+ /* By setting to 0xAA, we expose bugs in yy_init_globals. Leave at 0x00 for releases. */
+ memset(*ptr_yy_globals,0x00,sizeof(struct yyguts_t));
+
+ return yy_init_globals ( *ptr_yy_globals );
+}
+
+/* augl_lex_init_extra has the same functionality as augl_lex_init, but follows the
+ * convention of taking the scanner as the last argument. Note however, that
+ * this is a *pointer* to a scanner, as it will be allocated by this call (and
+ * is the reason, too, why this function also must handle its own declaration).
+ * The user defined value in the first argument will be available to augl_alloc in
+ * the yyextra field.
+ */
+
+int augl_lex_init_extra(YY_EXTRA_TYPE yy_user_defined,yyscan_t* ptr_yy_globals )
+
+{
+ struct yyguts_t dummy_yyguts;
+
+ augl_set_extra (yy_user_defined, &dummy_yyguts);
+
+ if (ptr_yy_globals == NULL){
+ errno = EINVAL;
+ return 1;
+ }
+
+ *ptr_yy_globals = (yyscan_t) augl_alloc ( sizeof( struct yyguts_t ), &dummy_yyguts );
+
+ if (*ptr_yy_globals == NULL){
+ errno = ENOMEM;
+ return 1;
+ }
+
+ /* By setting to 0xAA, we expose bugs in
+ yy_init_globals. Leave at 0x00 for releases. */
+ memset(*ptr_yy_globals,0x00,sizeof(struct yyguts_t));
+
+ augl_set_extra (yy_user_defined, *ptr_yy_globals);
+
+ return yy_init_globals ( *ptr_yy_globals );
+}
+
+static int yy_init_globals (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ /* Initialization is the same as for the non-reentrant scanner.
+ * This function is called from augl_lex_destroy(), so don't allocate here.
+ */
+
+ yyg->yy_buffer_stack = 0;
+ yyg->yy_buffer_stack_top = 0;
+ yyg->yy_buffer_stack_max = 0;
+ yyg->yy_c_buf_p = (char *) 0;
+ yyg->yy_init = 0;
+ yyg->yy_start = 0;
+
+ yyg->yy_start_stack_ptr = 0;
+ yyg->yy_start_stack_depth = 0;
+ yyg->yy_start_stack = NULL;
+
+/* Defined in main.c */
+#ifdef YY_STDINIT
+ yyin = stdin;
+ yyout = stdout;
+#else
+ yyin = (FILE *) 0;
+ yyout = (FILE *) 0;
+#endif
+
+ /* For future reference: Set errno on error, since we are called by
+ * augl_lex_init()
+ */
+ return 0;
+}
+
+/* augl_lex_destroy is for both reentrant and non-reentrant scanners. */
+int augl_lex_destroy (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+
+ /* Pop the buffer stack, destroying each element. */
+ while(YY_CURRENT_BUFFER){
+ augl__delete_buffer(YY_CURRENT_BUFFER ,yyscanner );
+ YY_CURRENT_BUFFER_LVALUE = NULL;
+ augl_pop_buffer_state(yyscanner);
+ }
+
+ /* Destroy the stack itself. */
+ augl_free(yyg->yy_buffer_stack ,yyscanner);
+ yyg->yy_buffer_stack = NULL;
+
+ /* Destroy the start condition stack. */
+ augl_free(yyg->yy_start_stack ,yyscanner );
+ yyg->yy_start_stack = NULL;
+
+ /* Reset the globals. This is important in a non-reentrant scanner so the next time
+ * augl_lex() is called, initialization will occur. */
+ yy_init_globals( yyscanner);
+
+ /* Destroy the main struct (reentrant only). */
+ augl_free ( yyscanner , yyscanner );
+ yyscanner = NULL;
+ return 0;
+}
+
+/*
+ * Internal utility routines.
+ */
+
+#ifndef yytext_ptr
+static void yy_flex_strncpy (char* s1, yyconst char * s2, int n , yyscan_t yyscanner)
+{
+ register int i;
+ for ( i = 0; i < n; ++i )
+ s1[i] = s2[i];
+}
+#endif
+
+#ifdef YY_NEED_STRLEN
+static int yy_flex_strlen (yyconst char * s , yyscan_t yyscanner)
+{
+ register int n;
+ for ( n = 0; s[n]; ++n )
+ ;
+
+ return n;
+}
+#endif
+
+void *augl_alloc (yy_size_t size , yyscan_t yyscanner)
+{
+ return (void *) malloc( size );
+}
+
+void *augl_realloc (void * ptr, yy_size_t size , yyscan_t yyscanner)
+{
+ /* The cast to (char *) in the following accommodates both
+ * implementations that use char* generic pointers, and those
+ * that use void* generic pointers. It works with the latter
+ * because both ANSI C and C++ allow castless assignment from
+ * any pointer type to void*, and deal with argument conversions
+ * as though doing an assignment.
+ */
+ return (void *) realloc( (char *) ptr, size );
+}
+
+void augl_free (void * ptr , yyscan_t yyscanner)
+{
+ free( (char *) ptr ); /* see augl_realloc() for (char *) cast */
+}
+
+#define YYTABLES_NAME "yytables"
+
+#line 182 "lexer.l"
+
+
+
+void augl_close_lexer(yyscan_t *scanner) {
+ FILE *fp = augl_get_in(scanner);
+
+ if (fp != NULL) {
+ fclose(fp);
+ augl_set_in(NULL, scanner);
+ }
+}
+
+int augl_init_lexer(struct state *state, yyscan_t *scanner) {
+ FILE *f;
+ struct string *name = state->info->filename;
+
+ f = fopen(name->str, "r");
+ if (f == NULL)
+ return -1;
+
+ if (augl_lex_init(scanner) != 0) {
+ fclose(f);
+ return -1;
+ }
+ augl_set_extra(state, *scanner);
+ augl_set_in(f, *scanner);
+ return 0;
+}
+
+struct info *augl_get_info(yyscan_t scanner) {
+ return augl_get_extra(scanner)->info;
+}
diff --git a/libraries/cmake/source/augeas/generated/linux/x86_64/code/parser.c b/libraries/cmake/source/augeas/generated/linux/x86_64/code/parser.c
new file mode 100644
index 00000000000..d8114f5d50a
--- /dev/null
+++ b/libraries/cmake/source/augeas/generated/linux/x86_64/code/parser.c
@@ -0,0 +1,2631 @@
+
+/* A Bison parser, made by GNU Bison 2.4.1. */
+
+/* Skeleton implementation for Bison's Yacc-like parsers in C
+
+ Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006
+ 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. */
+
+/* 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. */
+#define YYBISON 1
+
+/* Bison version. */
+#define YYBISON_VERSION "2.4.1"
+
+/* Skeleton name. */
+#define YYSKELETON_NAME "yacc.c"
+
+/* Pure parsers. */
+#define YYPURE 1
+
+/* Push parsers. */
+#define YYPUSH 0
+
+/* Pull parsers. */
+#define YYPULL 1
+
+/* Using locations. */
+#define YYLSP_NEEDED 1
+
+/* Substitute the variable and function names. */
+#define yyparse augl_parse
+#define yylex augl_lex
+#define yyerror augl_error
+#define yylval augl_lval
+#define yychar augl_char
+#define yydebug augl_debug
+#define yynerrs augl_nerrs
+#define yylloc augl_lloc
+
+/* Copy the first part of user declarations. */
+
+/* Line 189 of yacc.c */
+#line 1 "parser.y"
+
+
+#include
+
+#include "internal.h"
+#include "syntax.h"
+#include "list.h"
+#include "errcode.h"
+#include
+
+/* Work around a problem on FreeBSD where Bison looks for _STDLIB_H
+ * to see if stdlib.h has been included, but the system includes
+ * use _STDLIB_H_
+ */
+#if HAVE_STDLIB_H && ! defined _STDLIB_H
+# include
+# define _STDLIB_H 1
+#endif
+
+#define YYDEBUG 1
+
+int augl_parse_file(struct augeas *aug, const char *name, struct term **term);
+
+typedef void *yyscan_t;
+typedef struct info YYLTYPE;
+#define YYLTYPE_IS_DECLARED 1
+/* The lack of reference counting on filename is intentional */
+# define YYLLOC_DEFAULT(Current, Rhs, N) \
+ do { \
+ (Current).filename = augl_get_info(scanner)->filename; \
+ (Current).error = augl_get_info(scanner)->error; \
+ 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)
+
+
+/* Line 189 of yacc.c */
+#line 127 "parser.c"
+
+/* Enabling traces. */
+#ifndef YYDEBUG
+# define YYDEBUG 0
+#endif
+
+/* Enabling verbose error messages. */
+#ifdef YYERROR_VERBOSE
+# undef YYERROR_VERBOSE
+# define YYERROR_VERBOSE 1
+#else
+# define YYERROR_VERBOSE 1
+#endif
+
+/* Enabling the token table. */
+#ifndef YYTOKEN_TABLE
+# define YYTOKEN_TABLE 0
+#endif
+
+
+/* Tokens. */
+#ifndef YYTOKENTYPE
+# define YYTOKENTYPE
+ /* Put the tokens into the symbol table, so that GDB and other debuggers
+ know about them. */
+ enum yytokentype {
+ DQUOTED = 258,
+ REGEXP = 259,
+ LIDENT = 260,
+ UIDENT = 261,
+ QIDENT = 262,
+ ARROW = 263,
+ KW_MODULE = 264,
+ KW_AUTOLOAD = 265,
+ KW_LET = 266,
+ KW_LET_REC = 267,
+ KW_IN = 268,
+ KW_STRING = 269,
+ KW_REGEXP = 270,
+ KW_LENS = 271,
+ KW_TEST = 272,
+ KW_GET = 273,
+ KW_PUT = 274,
+ KW_AFTER = 275
+ };
+#endif
+/* Tokens. */
+#define DQUOTED 258
+#define REGEXP 259
+#define LIDENT 260
+#define UIDENT 261
+#define QIDENT 262
+#define ARROW 263
+#define KW_MODULE 264
+#define KW_AUTOLOAD 265
+#define KW_LET 266
+#define KW_LET_REC 267
+#define KW_IN 268
+#define KW_STRING 269
+#define KW_REGEXP 270
+#define KW_LENS 271
+#define KW_TEST 272
+#define KW_GET 273
+#define KW_PUT 274
+#define KW_AFTER 275
+
+
+
+
+#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
+typedef union YYSTYPE
+{
+
+/* Line 214 of yacc.c */
+#line 89 "parser.y"
+
+ struct term *term;
+ struct type *type;
+ struct ident *ident;
+ struct tree *tree;
+ char *string;
+ struct {
+ int nocase;
+ char *pattern;
+ } regexp;
+ int intval;
+ enum quant_tag quant;
+
+
+
+/* Line 214 of yacc.c */
+#line 219 "parser.c"
+} YYSTYPE;
+# define YYSTYPE_IS_TRIVIAL 1
+# define yystype YYSTYPE /* obsolescent; will be withdrawn */
+# define YYSTYPE_IS_DECLARED 1
+#endif
+
+#if ! defined YYLTYPE && ! defined YYLTYPE_IS_DECLARED
+typedef struct YYLTYPE
+{
+ int first_line;
+ int first_column;
+ int last_line;
+ int last_column;
+} YYLTYPE;
+# define yyltype YYLTYPE /* obsolescent; will be withdrawn */
+# define YYLTYPE_IS_DECLARED 1
+# define YYLTYPE_IS_TRIVIAL 1
+#endif
+
+/* "%code provides" blocks. */
+
+/* Line 261 of yacc.c */
+#line 46 "parser.y"
+
+#include "info.h"
+
+/* Track custom scanner state */
+struct state {
+ struct info *info;
+ unsigned int comment_depth;
+};
+
+
+
+
+/* Line 261 of yacc.c */
+#line 256 "parser.c"
+
+/* Copy the second part of user declarations. */
+
+/* Line 264 of yacc.c */
+#line 114 "parser.y"
+
+/* Lexer */
+extern int augl_lex (YYSTYPE * yylval_param,struct info * yylloc_param ,yyscan_t yyscanner);
+int augl_init_lexer(struct state *state, yyscan_t * scanner);
+void augl_close_lexer(yyscan_t *scanner);
+int augl_lex_destroy (yyscan_t yyscanner );
+int augl_get_lineno (yyscan_t yyscanner );
+int augl_get_column (yyscan_t yyscanner);
+struct info *augl_get_info(yyscan_t yyscanner);
+char *augl_get_text (yyscan_t yyscanner );
+
+static void augl_error(struct info *locp, struct term **term,
+ yyscan_t scanner, const char *s);
+
+/* TERM construction */
+ static struct info *clone_info(struct info *locp);
+ static struct term *make_module(char *ident, char *autoload,
+ struct term *decls,
+ struct info *locp);
+
+ static struct term *make_bind(char *ident, struct term *params,
+ struct term *exp, struct term *decls,
+ struct info *locp);
+ static struct term *make_bind_rec(char *ident, struct term *exp,
+ struct term *decls, struct info *locp);
+ static struct term *make_let(char *ident, struct term *params,
+ struct term *exp, struct term *body,
+ struct info *locp);
+ static struct term *make_binop(enum term_tag tag,
+ struct term *left, struct term *right,
+ struct info *locp);
+ static struct term *make_unop(enum term_tag tag,
+ struct term *exp, struct info *locp);
+ static struct term *make_ident(char *qname, struct info *locp);
+ static struct term *make_unit_term(struct info *locp);
+ static struct term *make_string_term(char *value, struct info *locp);
+ static struct term *make_regexp_term(char *pattern,
+ int nocase, struct info *locp);
+ static struct term *make_rep(struct term *exp, enum quant_tag quant,
+ struct info *locp);
+
+ static struct term *make_get_test(struct term *lens, struct term *arg,
+ struct info *info);
+ static struct term *make_put_test(struct term *lens, struct term *arg,
+ struct term *cmds, struct info *info);
+ static struct term *make_test(struct term *test, struct term *result,
+ enum test_result_tag tr_tag,
+ struct term *decls, struct info *locp);
+ static struct term *make_tree_value(struct tree *, struct info*);
+ static struct tree *tree_concat(struct tree *, struct tree *);
+
+#define LOC_MERGE(a, b, c) \
+ do { \
+ (a).filename = (b).filename; \
+ (a).first_line = (b).first_line; \
+ (a).first_column = (b).first_column; \
+ (a).last_line = (c).last_line; \
+ (a).last_column = (c).last_column; \
+ (a).error = (b).error; \
+ } while(0);
+
+
+
+/* Line 264 of yacc.c */
+#line 326 "parser.c"
+
+#ifdef short
+# undef short
+#endif
+
+#ifdef YYTYPE_UINT8
+typedef YYTYPE_UINT8 yytype_uint8;
+#else
+typedef unsigned char yytype_uint8;
+#endif
+
+#ifdef YYTYPE_INT8
+typedef YYTYPE_INT8 yytype_int8;
+#elif (defined __STDC__ || defined __C99__FUNC__ \
+ || defined __cplusplus || defined _MSC_VER)
+typedef signed char yytype_int8;
+#else
+typedef short int yytype_int8;
+#endif
+
+#ifdef YYTYPE_UINT16
+typedef YYTYPE_UINT16 yytype_uint16;
+#else
+typedef unsigned short int yytype_uint16;
+#endif
+
+#ifdef YYTYPE_INT16
+typedef YYTYPE_INT16 yytype_int16;
+#else
+typedef short int yytype_int16;
+#endif
+
+#ifndef YYSIZE_T
+# ifdef __SIZE_TYPE__
+# define YYSIZE_T __SIZE_TYPE__
+# elif defined size_t
+# define YYSIZE_T size_t
+# elif ! defined YYSIZE_T && (defined __STDC__ || defined __C99__FUNC__ \
+ || defined __cplusplus || defined _MSC_VER)
+# include /* INFRINGES ON USER NAME SPACE */
+# define YYSIZE_T size_t
+# else
+# define YYSIZE_T unsigned int
+# endif
+#endif
+
+#define YYSIZE_MAXIMUM ((YYSIZE_T) -1)
+
+#ifndef YY_
+# if 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
+
+/* Suppress unused-variable warnings by "using" E. */
+#if ! defined lint || defined __GNUC__
+# define YYUSE(e) ((void) (e))
+#else
+# define YYUSE(e) /* empty */
+#endif
+
+/* Identity function, used to suppress warnings about constant conditions. */
+#ifndef lint
+# define YYID(n) (n)
+#else
+#if (defined __STDC__ || defined __C99__FUNC__ \
+ || defined __cplusplus || defined _MSC_VER)
+static int
+YYID (int yyi)
+#else
+static int
+YYID (yyi)
+ int yyi;
+#endif
+{
+ return yyi;
+}
+#endif
+
+#if ! defined yyoverflow || YYERROR_VERBOSE
+
+/* 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 _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \
+ || defined __cplusplus || defined _MSC_VER)
+# include /* INFRINGES ON USER NAME SPACE */
+# ifndef _STDLIB_H
+# define _STDLIB_H 1
+# endif
+# endif
+# endif
+# endif
+# endif
+
+# ifdef YYSTACK_ALLOC
+ /* Pacify GCC's `empty if-body' warning. */
+# define YYSTACK_FREE(Ptr) do { /* empty */; } while (YYID (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 _STDLIB_H \
+ && ! ((defined YYMALLOC || defined malloc) \
+ && (defined YYFREE || defined free)))
+# include /* INFRINGES ON USER NAME SPACE */
+# ifndef _STDLIB_H
+# define _STDLIB_H 1
+# endif
+# endif
+# ifndef YYMALLOC
+# define YYMALLOC malloc
+# if ! defined malloc && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \
+ || defined __cplusplus || defined _MSC_VER)
+void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */
+# endif
+# endif
+# ifndef YYFREE
+# define YYFREE free
+# if ! defined free && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \
+ || defined __cplusplus || defined _MSC_VER)
+void free (void *); /* INFRINGES ON USER NAME SPACE */
+# endif
+# endif
+# endif
+#endif /* ! defined yyoverflow || YYERROR_VERBOSE */
+
+
+#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
+{
+ yytype_int16 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 (sizeof (union yyalloc) - 1)
+
+/* The size of an array large to enough to hold all stacks, each with
+ N elements. */
+# define YYSTACK_BYTES(N) \
+ ((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE) + sizeof (YYLTYPE)) \
+ + 2 * YYSTACK_GAP_MAXIMUM)
+
+/* Copy COUNT objects from FROM to TO. The source and destination do
+ not overlap. */
+# ifndef YYCOPY
+# if defined __GNUC__ && 1 < __GNUC__
+# define YYCOPY(To, From, Count) \
+ __builtin_memcpy (To, From, (Count) * sizeof (*(From)))
+# else
+# define YYCOPY(To, From, Count) \
+ do \
+ { \
+ YYSIZE_T yyi; \
+ for (yyi = 0; yyi < (Count); yyi++) \
+ (To)[yyi] = (From)[yyi]; \
+ } \
+ while (YYID (0))
+# endif
+# endif
+
+/* 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 \
+ { \
+ YYSIZE_T yynewbytes; \
+ YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \
+ Stack = &yyptr->Stack_alloc; \
+ yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \
+ yyptr += yynewbytes / sizeof (*yyptr); \
+ } \
+ while (YYID (0))
+
+#endif
+
+/* YYFINAL -- State number of the termination state. */
+#define YYFINAL 4
+/* YYLAST -- Last index in YYTABLE. */
+#define YYLAST 129
+
+/* YYNTOKENS -- Number of terminals. */
+#define YYNTOKENS 36
+/* YYNNTS -- Number of nonterminals. */
+#define YYNNTS 25
+/* YYNRULES -- Number of rules. */
+#define YYNRULES 61
+/* YYNRULES -- Number of states. */
+#define YYNSTATES 113
+
+/* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX. */
+#define YYUNDEFTOK 2
+#define YYMAXUTOK 275
+
+#define YYTRANSLATE(YYX) \
+ ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK)
+
+/* YYTRANSLATE[YYLEX] -- Bison symbol number corresponding to 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, 2, 2, 2, 2, 2, 2, 2,
+ 28, 29, 23, 32, 2, 26, 27, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 33, 24,
+ 2, 21, 2, 22, 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, 30, 2, 31, 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, 34, 25, 35, 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, 2, 1, 2, 3, 4,
+ 5, 6, 7, 8, 9, 10, 11, 12, 13, 14,
+ 15, 16, 17, 18, 19, 20
+};
+
+#if YYDEBUG
+/* YYPRHS[YYN] -- Index of the first RHS symbol of rule number YYN in
+ YYRHS. */
+static const yytype_uint8 yyprhs[] =
+{
+ 0, 0, 3, 9, 12, 13, 20, 26, 32, 38,
+ 39, 43, 49, 51, 53, 61, 63, 67, 69, 73,
+ 75, 77, 81, 83, 87, 89, 92, 94, 96, 98,
+ 100, 104, 108, 111, 114, 116, 118, 120, 122, 124,
+ 126, 128, 130, 133, 134, 140, 142, 144, 146, 150,
+ 152, 154, 156, 158, 162, 167, 171, 176, 177, 180,
+ 185, 187
+};
+
+/* YYRHS -- A `-1'-separated list of the rules' RHS. */
+static const yytype_int8 yyrhs[] =
+{
+ 37, 0, -1, 9, 6, 21, 38, 39, -1, 10,
+ 5, -1, -1, 11, 5, 52, 21, 42, 39, -1,
+ 12, 5, 21, 42, 39, -1, 17, 40, 21, 42,
+ 39, -1, 17, 40, 21, 41, 39, -1, -1, 48,
+ 18, 42, -1, 48, 19, 48, 20, 42, -1, 22,
+ -1, 23, -1, 11, 5, 52, 21, 42, 13, 42,
+ -1, 43, -1, 43, 24, 44, -1, 44, -1, 44,
+ 25, 45, -1, 45, -1, 57, -1, 45, 26, 46,
+ -1, 46, -1, 46, 27, 47, -1, 47, -1, 47,
+ 49, -1, 49, -1, 51, -1, 3, -1, 4, -1,
+ 28, 42, 29, -1, 30, 42, 31, -1, 28, 29,
+ -1, 48, 50, -1, 48, -1, 23, -1, 32, -1,
+ 22, -1, 5, -1, 7, -1, 18, -1, 19, -1,
+ 53, 52, -1, -1, 28, 54, 33, 55, 29, -1,
+ 5, -1, 18, -1, 19, -1, 56, 8, 55, -1,
+ 56, -1, 14, -1, 15, -1, 16, -1, 28, 55,
+ 29, -1, 57, 34, 59, 35, -1, 34, 59, 35,
+ -1, 58, 34, 59, 35, -1, -1, 60, 58, -1,
+ 60, 21, 3, 58, -1, 3, -1, -1
+};
+
+/* YYRLINE[YYN] -- source line where rule number YYN was defined. */
+static const yytype_uint16 yyrline[] =
+{
+ 0, 179, 179, 182, 185, 187, 192, 197, 202, 208,
+ 212, 214, 217, 219, 223, 228, 230, 232, 235, 237,
+ 239, 242, 244, 247, 249, 252, 254, 257, 259, 261,
+ 263, 265, 267, 270, 272, 275, 277, 279, 282, 284,
+ 286, 288, 291, 294, 296, 299, 301, 303, 306, 308,
+ 311, 313, 315, 317, 320, 322, 325, 330, 332, 336,
+ 340, 342
+};
+#endif
+
+#if YYDEBUG || YYERROR_VERBOSE || YYTOKEN_TABLE
+/* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM.
+ First, the terminals, then, starting at YYNTOKENS, nonterminals. */
+static const char *const yytname[] =
+{
+ "$end", "error", "$undefined", "DQUOTED", "REGEXP", "LIDENT", "UIDENT",
+ "QIDENT", "ARROW", "KW_MODULE", "KW_AUTOLOAD", "KW_LET", "KW_LET_REC",
+ "KW_IN", "KW_STRING", "KW_REGEXP", "KW_LENS", "KW_TEST", "KW_GET",
+ "KW_PUT", "KW_AFTER", "'='", "'?'", "'*'", "';'", "'|'", "'-'", "'.'",
+ "'('", "')'", "'['", "']'", "'+'", "':'", "'{'", "'}'", "$accept",
+ "start", "autoload", "decls", "test_exp", "test_special_res", "exp",
+ "composeexp", "unionexp", "minusexp", "catexp", "appexp", "aexp", "rexp",
+ "rep", "qid", "param_list", "param", "id", "type", "atype", "tree_const",
+ "tree_const2", "tree_branch", "tree_label", 0
+};
+#endif
+
+# ifdef YYPRINT
+/* YYTOKNUM[YYLEX-NUM] -- Internal token number corresponding to
+ token YYLEX-NUM. */
+static const yytype_uint16 yytoknum[] =
+{
+ 0, 256, 257, 258, 259, 260, 261, 262, 263, 264,
+ 265, 266, 267, 268, 269, 270, 271, 272, 273, 274,
+ 275, 61, 63, 42, 59, 124, 45, 46, 40, 41,
+ 91, 93, 43, 58, 123, 125
+};
+# endif
+
+/* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */
+static const yytype_uint8 yyr1[] =
+{
+ 0, 36, 37, 38, 38, 39, 39, 39, 39, 39,
+ 40, 40, 41, 41, 42, 42, 43, 43, 44, 44,
+ 44, 45, 45, 46, 46, 47, 47, 48, 48, 48,
+ 48, 48, 48, 49, 49, 50, 50, 50, 51, 51,
+ 51, 51, 52, 52, 53, 54, 54, 54, 55, 55,
+ 56, 56, 56, 56, 57, 57, 58, 58, 59, 59,
+ 60, 60
+};
+
+/* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN. */
+static const yytype_uint8 yyr2[] =
+{
+ 0, 2, 5, 2, 0, 6, 5, 5, 5, 0,
+ 3, 5, 1, 1, 7, 1, 3, 1, 3, 1,
+ 1, 3, 1, 3, 1, 2, 1, 1, 1, 1,
+ 3, 3, 2, 2, 1, 1, 1, 1, 1, 1,
+ 1, 1, 2, 0, 5, 1, 1, 1, 3, 1,
+ 1, 1, 1, 3, 4, 3, 4, 0, 2, 4,
+ 1, 0
+};
+
+/* YYDEFACT[STATE-NAME] -- Default rule to reduce with in state
+ STATE-NUM when YYTABLE doesn't specify something else to do. Zero
+ means the default is an error. */
+static const yytype_uint8 yydefact[] =
+{
+ 0, 0, 0, 0, 1, 4, 0, 9, 3, 0,
+ 0, 0, 2, 43, 0, 28, 29, 38, 39, 40,
+ 41, 0, 0, 0, 0, 27, 0, 0, 43, 0,
+ 0, 32, 61, 0, 15, 17, 19, 22, 24, 34,
+ 26, 20, 0, 0, 0, 0, 45, 46, 47, 0,
+ 0, 42, 9, 43, 60, 0, 57, 30, 0, 0,
+ 0, 0, 25, 37, 35, 36, 33, 61, 31, 12,
+ 13, 9, 9, 10, 0, 0, 9, 6, 0, 55,
+ 0, 58, 16, 18, 21, 23, 0, 8, 7, 0,
+ 50, 51, 52, 0, 0, 49, 5, 0, 57, 61,
+ 54, 11, 0, 44, 0, 0, 59, 0, 53, 48,
+ 0, 56, 14
+};
+
+/* YYDEFGOTO[NTERM-NUM]. */
+static const yytype_int8 yydefgoto[] =
+{
+ -1, 2, 7, 12, 23, 71, 33, 34, 35, 36,
+ 37, 38, 39, 40, 66, 25, 27, 28, 49, 94,
+ 95, 41, 81, 55, 56
+};
+
+/* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
+ STATE-NUM. */
+#define YYPACT_NINF -90
+static const yytype_int8 yypact[] =
+{
+ -1, 8, 16, -4, -90, 14, 26, 53, -90, 27,
+ 29, 92, -90, 11, 25, -90, -90, -90, -90, -90,
+ -90, 50, 55, 28, -6, -90, 1, 30, 11, 55,
+ 38, -90, 44, 34, 52, 57, 51, 59, 92, 49,
+ -90, 64, 56, 22, 55, 92, -90, -90, -90, 60,
+ 55, -90, 53, 11, -90, 65, 80, -90, 87, 92,
+ 92, 92, -90, -90, -90, -90, -90, 44, -90, -90,
+ -90, 53, 53, -90, 82, -5, 53, -90, 83, -90,
+ 100, 73, 57, 51, 59, 92, 74, -90, -90, 55,
+ -90, -90, -90, -5, 79, 104, -90, 55, -90, 44,
+ -90, -90, 84, -90, -5, 101, 73, 81, -90, -90,
+ 55, -90, -90
+};
+
+/* YYPGOTO[NTERM-NUM]. */
+static const yytype_int8 yypgoto[] =
+{
+ -90, -90, -90, -34, -90, -90, -22, -90, 61, 66,
+ 58, 62, -9, -37, -90, -90, -23, -90, -90, -89,
+ -90, -90, 31, -64, -90
+};
+
+/* YYTABLE[YYPACT[STATE-NUM]]. What to do in state STATE-NUM. If
+ positive, shift that token. If negative, reduce the rule which
+ number is the opposite. If zero, do what YYDEFACT says.
+ If YYTABLE_NINF, syntax error. */
+#define YYTABLE_NINF -1
+static const yytype_uint8 yytable[] =
+{
+ 42, 62, 24, 86, 102, 51, 46, 52, 1, 90,
+ 91, 92, 44, 45, 3, 109, 4, 5, 77, 47,
+ 48, 72, 73, 93, 6, 15, 16, 17, 76, 18,
+ 78, 8, 13, 30, 14, 107, 74, 87, 88, 26,
+ 19, 20, 96, 53, 69, 70, 29, 54, 62, 43,
+ 21, 50, 22, 15, 16, 17, 32, 18, 15, 16,
+ 17, 30, 18, 57, 9, 10, 30, 101, 19, 20,
+ 11, 63, 64, 19, 20, 105, 58, 60, 21, 31,
+ 22, 65, 59, 21, 32, 22, 61, 68, 112, 32,
+ 15, 16, 17, 75, 18, 15, 16, 17, 67, 18,
+ 79, 80, 89, 98, 97, 19, 20, 99, 103, 100,
+ 19, 20, 104, 108, 110, 21, 111, 22, 84, 82,
+ 21, 32, 22, 85, 0, 83, 0, 0, 0, 106
+};
+
+static const yytype_int8 yycheck[] =
+{
+ 22, 38, 11, 67, 93, 28, 5, 29, 9, 14,
+ 15, 16, 18, 19, 6, 104, 0, 21, 52, 18,
+ 19, 43, 44, 28, 10, 3, 4, 5, 50, 7,
+ 53, 5, 5, 11, 5, 99, 45, 71, 72, 28,
+ 18, 19, 76, 5, 22, 23, 21, 3, 85, 21,
+ 28, 21, 30, 3, 4, 5, 34, 7, 3, 4,
+ 5, 11, 7, 29, 11, 12, 11, 89, 18, 19,
+ 17, 22, 23, 18, 19, 97, 24, 26, 28, 29,
+ 30, 32, 25, 28, 34, 30, 27, 31, 110, 34,
+ 3, 4, 5, 33, 7, 3, 4, 5, 34, 7,
+ 35, 21, 20, 3, 21, 18, 19, 34, 29, 35,
+ 18, 19, 8, 29, 13, 28, 35, 30, 60, 58,
+ 28, 34, 30, 61, -1, 59, -1, -1, -1, 98
+};
+
+/* YYSTOS[STATE-NUM] -- The (internal number of the) accessing
+ symbol of state STATE-NUM. */
+static const yytype_uint8 yystos[] =
+{
+ 0, 9, 37, 6, 0, 21, 10, 38, 5, 11,
+ 12, 17, 39, 5, 5, 3, 4, 5, 7, 18,
+ 19, 28, 30, 40, 48, 51, 28, 52, 53, 21,
+ 11, 29, 34, 42, 43, 44, 45, 46, 47, 48,
+ 49, 57, 42, 21, 18, 19, 5, 18, 19, 54,
+ 21, 52, 42, 5, 3, 59, 60, 29, 24, 25,
+ 26, 27, 49, 22, 23, 32, 50, 34, 31, 22,
+ 23, 41, 42, 42, 48, 33, 42, 39, 52, 35,
+ 21, 58, 44, 45, 46, 47, 59, 39, 39, 20,
+ 14, 15, 16, 28, 55, 56, 39, 21, 3, 34,
+ 35, 42, 55, 29, 8, 42, 58, 59, 29, 55,
+ 13, 35, 42
+};
+
+#define yyerrok (yyerrstatus = 0)
+#define yyclearin (yychar = YYEMPTY)
+#define YYEMPTY (-2)
+#define YYEOF 0
+
+#define YYACCEPT goto yyacceptlab
+#define YYABORT goto yyabortlab
+#define YYERROR goto yyerrorlab
+
+
+/* Like YYERROR except do call yyerror. This remains here temporarily
+ to ease the transition to the new meaning of YYERROR, for GCC.
+ Once GCC version 2 has supplanted version 1, this can go. */
+
+#define YYFAIL goto yyerrlab
+
+#define YYRECOVERING() (!!yyerrstatus)
+
+#define YYBACKUP(Token, Value) \
+do \
+ if (yychar == YYEMPTY && yylen == 1) \
+ { \
+ yychar = (Token); \
+ yylval = (Value); \
+ yytoken = YYTRANSLATE (yychar); \
+ YYPOPSTACK (1); \
+ goto yybackup; \
+ } \
+ else \
+ { \
+ yyerror (&yylloc, term, scanner, YY_("syntax error: cannot back up")); \
+ YYERROR; \
+ } \
+while (YYID (0))
+
+
+#define YYTERROR 1
+#define YYERRCODE 256
+
+
+/* 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). */
+
+#define YYRHSLOC(Rhs, K) ((Rhs)[K])
+#ifndef YYLLOC_DEFAULT
+# define YYLLOC_DEFAULT(Current, Rhs, N) \
+ do \
+ if (YYID (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 (YYID (0))
+#endif
+
+
+/* YY_LOCATION_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 YY_LOCATION_PRINT
+# if YYLTYPE_IS_TRIVIAL
+# define YY_LOCATION_PRINT(File, Loc) \
+ fprintf (File, "%d.%d-%d.%d", \
+ (Loc).first_line, (Loc).first_column, \
+ (Loc).last_line, (Loc).last_column)
+# else
+# define YY_LOCATION_PRINT(File, Loc) ((void) 0)
+# endif
+#endif
+
+
+/* YYLEX -- calling `yylex' with the right arguments. */
+
+#ifdef YYLEX_PARAM
+# define YYLEX yylex (&yylval, &yylloc, YYLEX_PARAM)
+#else
+# define YYLEX yylex (&yylval, &yylloc, scanner)
+#endif
+
+/* 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 (YYID (0))
+
+# define YY_SYMBOL_PRINT(Title, Type, Value, Location) \
+do { \
+ if (yydebug) \
+ { \
+ YYFPRINTF (stderr, "%s ", Title); \
+ yy_symbol_print (stderr, \
+ Type, Value, Location, term, scanner); \
+ YYFPRINTF (stderr, "\n"); \
+ } \
+} while (YYID (0))
+
+
+/*--------------------------------.
+| Print this symbol on YYOUTPUT. |
+`--------------------------------*/
+
+/*ARGSUSED*/
+#if (defined __STDC__ || defined __C99__FUNC__ \
+ || defined __cplusplus || defined _MSC_VER)
+static void
+yy_symbol_value_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep, YYLTYPE const * const yylocationp, struct term **term, yyscan_t scanner)
+#else
+static void
+yy_symbol_value_print (yyoutput, yytype, yyvaluep, yylocationp, term, scanner)
+ FILE *yyoutput;
+ int yytype;
+ YYSTYPE const * const yyvaluep;
+ YYLTYPE const * const yylocationp;
+ struct term **term;
+ yyscan_t scanner;
+#endif
+{
+ if (!yyvaluep)
+ return;
+ YYUSE (yylocationp);
+ YYUSE (term);
+ YYUSE (scanner);
+# ifdef YYPRINT
+ if (yytype < YYNTOKENS)
+ YYPRINT (yyoutput, yytoknum[yytype], *yyvaluep);
+# else
+ YYUSE (yyoutput);
+# endif
+ switch (yytype)
+ {
+ default:
+ break;
+ }
+}
+
+
+/*--------------------------------.
+| Print this symbol on YYOUTPUT. |
+`--------------------------------*/
+
+#if (defined __STDC__ || defined __C99__FUNC__ \
+ || defined __cplusplus || defined _MSC_VER)
+static void
+yy_symbol_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep, YYLTYPE const * const yylocationp, struct term **term, yyscan_t scanner)
+#else
+static void
+yy_symbol_print (yyoutput, yytype, yyvaluep, yylocationp, term, scanner)
+ FILE *yyoutput;
+ int yytype;
+ YYSTYPE const * const yyvaluep;
+ YYLTYPE const * const yylocationp;
+ struct term **term;
+ yyscan_t scanner;
+#endif
+{
+ if (yytype < YYNTOKENS)
+ YYFPRINTF (yyoutput, "token %s (", yytname[yytype]);
+ else
+ YYFPRINTF (yyoutput, "nterm %s (", yytname[yytype]);
+
+ YY_LOCATION_PRINT (yyoutput, *yylocationp);
+ YYFPRINTF (yyoutput, ": ");
+ yy_symbol_value_print (yyoutput, yytype, yyvaluep, yylocationp, term, scanner);
+ YYFPRINTF (yyoutput, ")");
+}
+
+/*------------------------------------------------------------------.
+| yy_stack_print -- Print the state stack from its BOTTOM up to its |
+| TOP (included). |
+`------------------------------------------------------------------*/
+
+#if (defined __STDC__ || defined __C99__FUNC__ \
+ || defined __cplusplus || defined _MSC_VER)
+static void
+yy_stack_print (yytype_int16 *yybottom, yytype_int16 *yytop)
+#else
+static void
+yy_stack_print (yybottom, yytop)
+ yytype_int16 *yybottom;
+ yytype_int16 *yytop;
+#endif
+{
+ 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 (YYID (0))
+
+
+/*------------------------------------------------.
+| Report that the YYRULE is going to be reduced. |
+`------------------------------------------------*/
+
+#if (defined __STDC__ || defined __C99__FUNC__ \
+ || defined __cplusplus || defined _MSC_VER)
+static void
+yy_reduce_print (YYSTYPE *yyvsp, YYLTYPE *yylsp, int yyrule, struct term **term, yyscan_t scanner)
+#else
+static void
+yy_reduce_print (yyvsp, yylsp, yyrule, term, scanner)
+ YYSTYPE *yyvsp;
+ YYLTYPE *yylsp;
+ int yyrule;
+ struct term **term;
+ yyscan_t scanner;
+#endif
+{
+ int yynrhs = yyr2[yyrule];
+ int yyi;
+ unsigned long int yylno = yyrline[yyrule];
+ YYFPRINTF (stderr, "Reducing stack by rule %d (line %lu):\n",
+ yyrule - 1, yylno);
+ /* The symbols being reduced. */
+ for (yyi = 0; yyi < yynrhs; yyi++)
+ {
+ YYFPRINTF (stderr, " $%d = ", yyi + 1);
+ yy_symbol_print (stderr, yyrhs[yyprhs[yyrule] + yyi],
+ &(yyvsp[(yyi + 1) - (yynrhs)])
+ , &(yylsp[(yyi + 1) - (yynrhs)]) , term, scanner);
+ YYFPRINTF (stderr, "\n");
+ }
+}
+
+# define YY_REDUCE_PRINT(Rule) \
+do { \
+ if (yydebug) \
+ yy_reduce_print (yyvsp, yylsp, Rule, term, scanner); \
+} while (YYID (0))
+
+/* Nonzero means print parse trace. It is left uninitialized so that
+ multiple parsers can coexist. */
+int yydebug;
+#else /* !YYDEBUG */
+# define YYDPRINTF(Args)
+# define YY_SYMBOL_PRINT(Title, Type, 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
+
+
+
+#if YYERROR_VERBOSE
+
+# ifndef yystrlen
+# if defined __GLIBC__ && defined _STRING_H
+# define yystrlen strlen
+# else
+/* Return the length of YYSTR. */
+#if (defined __STDC__ || defined __C99__FUNC__ \
+ || defined __cplusplus || defined _MSC_VER)
+static YYSIZE_T
+yystrlen (const char *yystr)
+#else
+static YYSIZE_T
+yystrlen (yystr)
+ const char *yystr;
+#endif
+{
+ YYSIZE_T yylen;
+ for (yylen = 0; yystr[yylen]; yylen++)
+ continue;
+ return yylen;
+}
+# endif
+# endif
+
+# ifndef yystpcpy
+# if defined __GLIBC__ && defined _STRING_H && defined _GNU_SOURCE
+# define yystpcpy stpcpy
+# else
+/* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in
+ YYDEST. */
+#if (defined __STDC__ || defined __C99__FUNC__ \
+ || defined __cplusplus || defined _MSC_VER)
+static char *
+yystpcpy (char *yydest, const char *yysrc)
+#else
+static char *
+yystpcpy (yydest, yysrc)
+ char *yydest;
+ const char *yysrc;
+#endif
+{
+ char *yyd = yydest;
+ const char *yys = yysrc;
+
+ while ((*yyd++ = *yys++) != '\0')
+ continue;
+
+ return yyd - 1;
+}
+# endif
+# endif
+
+# ifndef yytnamerr
+/* Copy to YYRES the contents of YYSTR after stripping away unnecessary
+ quotes and backslashes, so that it's suitable for yyerror. The
+ heuristic is that double-quoting is unnecessary unless the string
+ contains an apostrophe, a comma, or backslash (other than
+ backslash-backslash). YYSTR is taken from yytname. If YYRES is
+ null, do not copy; instead, return the length of what the result
+ would have been. */
+static YYSIZE_T
+yytnamerr (char *yyres, const char *yystr)
+{
+ if (*yystr == '"')
+ {
+ YYSIZE_T yyn = 0;
+ char const *yyp = yystr;
+
+ for (;;)
+ switch (*++yyp)
+ {
+ case '\'':
+ case ',':
+ goto do_not_strip_quotes;
+
+ case '\\':
+ if (*++yyp != '\\')
+ goto do_not_strip_quotes;
+ /* Fall through. */
+ default:
+ if (yyres)
+ yyres[yyn] = *yyp;
+ yyn++;
+ break;
+
+ case '"':
+ if (yyres)
+ yyres[yyn] = '\0';
+ return yyn;
+ }
+ do_not_strip_quotes: ;
+ }
+
+ if (! yyres)
+ return yystrlen (yystr);
+
+ return yystpcpy (yyres, yystr) - yyres;
+}
+# endif
+
+/* Copy into YYRESULT an error message about the unexpected token
+ YYCHAR while in state YYSTATE. Return the number of bytes copied,
+ including the terminating null byte. If YYRESULT is null, do not
+ copy anything; just return the number of bytes that would be
+ copied. As a special case, return 0 if an ordinary "syntax error"
+ message will do. Return YYSIZE_MAXIMUM if overflow occurs during
+ size calculation. */
+static YYSIZE_T
+yysyntax_error (char *yyresult, int yystate, int yychar)
+{
+ int yyn = yypact[yystate];
+
+ if (! (YYPACT_NINF < yyn && yyn <= YYLAST))
+ return 0;
+ else
+ {
+ int yytype = YYTRANSLATE (yychar);
+ YYSIZE_T yysize0 = yytnamerr (0, yytname[yytype]);
+ YYSIZE_T yysize = yysize0;
+ YYSIZE_T yysize1;
+ int yysize_overflow = 0;
+ enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 };
+ char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM];
+ int yyx;
+
+# if 0
+ /* This is so xgettext sees the translatable formats that are
+ constructed on the fly. */
+ YY_("syntax error, unexpected %s");
+ YY_("syntax error, unexpected %s, expecting %s");
+ YY_("syntax error, unexpected %s, expecting %s or %s");
+ YY_("syntax error, unexpected %s, expecting %s or %s or %s");
+ YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s");
+# endif
+ char *yyfmt;
+ char const *yyf;
+ static char const yyunexpected[] = "syntax error, unexpected %s";
+ static char const yyexpecting[] = ", expecting %s";
+ static char const yyor[] = " or %s";
+ char yyformat[sizeof yyunexpected
+ + sizeof yyexpecting - 1
+ + ((YYERROR_VERBOSE_ARGS_MAXIMUM - 2)
+ * (sizeof yyor - 1))];
+ char const *yyprefix = yyexpecting;
+
+ /* Start YYX at -YYN if negative to avoid negative indexes in
+ YYCHECK. */
+ int yyxbegin = yyn < 0 ? -yyn : 0;
+
+ /* Stay within bounds of both yycheck and yytname. */
+ int yychecklim = YYLAST - yyn + 1;
+ int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS;
+ int yycount = 1;
+
+ yyarg[0] = yytname[yytype];
+ yyfmt = yystpcpy (yyformat, yyunexpected);
+
+ for (yyx = yyxbegin; yyx < yyxend; ++yyx)
+ if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR)
+ {
+ if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM)
+ {
+ yycount = 1;
+ yysize = yysize0;
+ yyformat[sizeof yyunexpected - 1] = '\0';
+ break;
+ }
+ yyarg[yycount++] = yytname[yyx];
+ yysize1 = yysize + yytnamerr (0, yytname[yyx]);
+ yysize_overflow |= (yysize1 < yysize);
+ yysize = yysize1;
+ yyfmt = yystpcpy (yyfmt, yyprefix);
+ yyprefix = yyor;
+ }
+
+ yyf = YY_(yyformat);
+ yysize1 = yysize + yystrlen (yyf);
+ yysize_overflow |= (yysize1 < yysize);
+ yysize = yysize1;
+
+ if (yysize_overflow)
+ return YYSIZE_MAXIMUM;
+
+ if (yyresult)
+ {
+ /* Avoid sprintf, as that infringes on the user's name space.
+ Don't have undefined behavior even if the translation
+ produced a string with the wrong number of "%s"s. */
+ char *yyp = yyresult;
+ int yyi = 0;
+ while ((*yyp = *yyf) != '\0')
+ {
+ if (*yyp == '%' && yyf[1] == 's' && yyi < yycount)
+ {
+ yyp += yytnamerr (yyp, yyarg[yyi++]);
+ yyf += 2;
+ }
+ else
+ {
+ yyp++;
+ yyf++;
+ }
+ }
+ }
+ return yysize;
+ }
+}
+#endif /* YYERROR_VERBOSE */
+
+
+/*-----------------------------------------------.
+| Release the memory associated to this symbol. |
+`-----------------------------------------------*/
+
+/*ARGSUSED*/
+#if (defined __STDC__ || defined __C99__FUNC__ \
+ || defined __cplusplus || defined _MSC_VER)
+static void
+yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep, YYLTYPE *yylocationp, struct term **term, yyscan_t scanner)
+#else
+static void
+yydestruct (yymsg, yytype, yyvaluep, yylocationp, term, scanner)
+ const char *yymsg;
+ int yytype;
+ YYSTYPE *yyvaluep;
+ YYLTYPE *yylocationp;
+ struct term **term;
+ yyscan_t scanner;
+#endif
+{
+ YYUSE (yyvaluep);
+ YYUSE (yylocationp);
+ YYUSE (term);
+ YYUSE (scanner);
+
+ if (!yymsg)
+ yymsg = "Deleting";
+ YY_SYMBOL_PRINT (yymsg, yytype, yyvaluep, yylocationp);
+
+ switch (yytype)
+ {
+
+ default:
+ break;
+ }
+}
+
+/* Prevent warnings from -Wmissing-prototypes. */
+#ifdef YYPARSE_PARAM
+#if defined __STDC__ || defined __cplusplus
+int yyparse (void *YYPARSE_PARAM);
+#else
+int yyparse ();
+#endif
+#else /* ! YYPARSE_PARAM */
+#if defined __STDC__ || defined __cplusplus
+int yyparse (struct term **term, yyscan_t scanner);
+#else
+int yyparse ();
+#endif
+#endif /* ! YYPARSE_PARAM */
+
+
+
+
+
+/*-------------------------.
+| yyparse or yypush_parse. |
+`-------------------------*/
+
+#ifdef YYPARSE_PARAM
+#if (defined __STDC__ || defined __C99__FUNC__ \
+ || defined __cplusplus || defined _MSC_VER)
+int
+yyparse (void *YYPARSE_PARAM)
+#else
+int
+yyparse (YYPARSE_PARAM)
+ void *YYPARSE_PARAM;
+#endif
+#else /* ! YYPARSE_PARAM */
+#if (defined __STDC__ || defined __C99__FUNC__ \
+ || defined __cplusplus || defined _MSC_VER)
+int
+yyparse (struct term **term, yyscan_t scanner)
+#else
+int
+yyparse (term, scanner)
+ struct term **term;
+ yyscan_t scanner;
+#endif
+#endif
+{
+/* The lookahead symbol. */
+int yychar;
+
+/* The semantic value of the lookahead symbol. */
+YYSTYPE yylval;
+
+/* Location data for the lookahead symbol. */
+YYLTYPE yylloc;
+
+ /* Number of syntax errors so far. */
+ int yynerrs;
+
+ int yystate;
+ /* Number of tokens to shift before error messages enabled. */
+ int yyerrstatus;
+
+ /* The stacks and their tools:
+ `yyss': related to states.
+ `yyvs': related to semantic values.
+ `yyls': related to locations.
+
+ Refer to the stacks thru separate pointers, to allow yyoverflow
+ to reallocate them elsewhere. */
+
+ /* The state stack. */
+ yytype_int16 yyssa[YYINITDEPTH];
+ yytype_int16 *yyss;
+ yytype_int16 *yyssp;
+
+ /* The semantic value stack. */
+ YYSTYPE yyvsa[YYINITDEPTH];
+ YYSTYPE *yyvs;
+ YYSTYPE *yyvsp;
+
+ /* The location stack. */
+ YYLTYPE yylsa[YYINITDEPTH];
+ YYLTYPE *yyls;
+ YYLTYPE *yylsp;
+
+ /* The locations where the error started and ended. */
+ YYLTYPE yyerror_range[2];
+
+ YYSIZE_T yystacksize;
+
+ int yyn;
+ int yyresult;
+ /* Lookahead token as an internal (translated) token number. */
+ int yytoken;
+ /* The variables used to return semantic value and location from the
+ action routines. */
+ YYSTYPE yyval;
+ YYLTYPE yyloc;
+
+#if YYERROR_VERBOSE
+ /* Buffer for error messages, and its allocated size. */
+ char yymsgbuf[128];
+ char *yymsg = yymsgbuf;
+ YYSIZE_T yymsg_alloc = sizeof yymsgbuf;
+#endif
+
+#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;
+
+ yytoken = 0;
+ yyss = yyssa;
+ yyvs = yyvsa;
+ yyls = yylsa;
+ yystacksize = YYINITDEPTH;
+
+ YYDPRINTF ((stderr, "Starting parse\n"));
+
+ yystate = 0;
+ yyerrstatus = 0;
+ yynerrs = 0;
+ yychar = YYEMPTY; /* Cause a token to be read. */
+
+ /* Initialize stack pointers.
+ Waste one element of value and location stack
+ so that they stay on the same level as the state stack.
+ The wasted elements are never initialized. */
+ yyssp = yyss;
+ yyvsp = yyvs;
+ yylsp = yyls;
+
+#if YYLTYPE_IS_TRIVIAL
+ /* Initialize the default location before parsing starts. */
+ yylloc.first_line = yylloc.last_line = 1;
+ yylloc.first_column = yylloc.last_column = 1;
+#endif
+
+/* User initialization code. */
+
+/* Line 1242 of yacc.c */
+#line 66 "parser.y"
+{
+ yylloc.first_line = 1;
+ yylloc.first_column = 0;
+ yylloc.last_line = 1;
+ yylloc.last_column = 0;
+ yylloc.filename = augl_get_info(scanner)->filename;
+ yylloc.error = augl_get_info(scanner)->error;
+}
+
+/* Line 1242 of yacc.c */
+#line 1496 "parser.c"
+ 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:
+ *yyssp = yystate;
+
+ if (yyss + yystacksize - 1 <= yyssp)
+ {
+ /* Get the current used size of the three stacks, in elements. */
+ YYSIZE_T yysize = yyssp - yyss + 1;
+
+#ifdef 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. */
+ YYSTYPE *yyvs1 = yyvs;
+ yytype_int16 *yyss1 = yyss;
+ 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 * sizeof (*yyssp),
+ &yyvs1, yysize * sizeof (*yyvsp),
+ &yyls1, yysize * sizeof (*yylsp),
+ &yystacksize);
+
+ yyls = yyls1;
+ yyss = yyss1;
+ yyvs = yyvs1;
+ }
+#else /* no yyoverflow */
+# ifndef YYSTACK_RELOCATE
+ goto yyexhaustedlab;
+# else
+ /* Extend the stack our own way. */
+ if (YYMAXDEPTH <= yystacksize)
+ goto yyexhaustedlab;
+ yystacksize *= 2;
+ if (YYMAXDEPTH < yystacksize)
+ yystacksize = YYMAXDEPTH;
+
+ {
+ yytype_int16 *yyss1 = yyss;
+ union yyalloc *yyptr =
+ (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize));
+ if (! yyptr)
+ goto yyexhaustedlab;
+ 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
+#endif /* no yyoverflow */
+
+ yyssp = yyss + yysize - 1;
+ yyvsp = yyvs + yysize - 1;
+ yylsp = yyls + yysize - 1;
+
+ YYDPRINTF ((stderr, "Stack size increased to %lu\n",
+ (unsigned long int) yystacksize));
+
+ if (yyss + yystacksize - 1 <= yyssp)
+ YYABORT;
+ }
+
+ YYDPRINTF ((stderr, "Entering state %d\n", yystate));
+
+ 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 (yyn == YYPACT_NINF)
+ goto yydefault;
+
+ /* Not known => get a lookahead token if don't already have one. */
+
+ /* YYCHAR is either YYEMPTY or YYEOF or a valid lookahead symbol. */
+ if (yychar == YYEMPTY)
+ {
+ YYDPRINTF ((stderr, "Reading a token: "));
+ yychar = YYLEX;
+ }
+
+ if (yychar <= YYEOF)
+ {
+ yychar = yytoken = YYEOF;
+ YYDPRINTF ((stderr, "Now at end of input.\n"));
+ }
+ 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 (yyn == 0 || yyn == YYTABLE_NINF)
+ 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);
+
+ /* Discard the shifted token. */
+ yychar = YYEMPTY;
+
+ yystate = yyn;
+ *++yyvsp = yylval;
+ *++yylsp = yylloc;
+ 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);
+ YY_REDUCE_PRINT (yyn);
+ switch (yyn)
+ {
+ case 2:
+
+/* Line 1455 of yacc.c */
+#line 180 "parser.y"
+ { (*term) = make_module((yyvsp[(2) - (5)].string), (yyvsp[(4) - (5)].string), (yyvsp[(5) - (5)].term), &(yylsp[(1) - (5)])); }
+ break;
+
+ case 3:
+
+/* Line 1455 of yacc.c */
+#line 183 "parser.y"
+ { (yyval.string) = (yyvsp[(2) - (2)].string); }
+ break;
+
+ case 4:
+
+/* Line 1455 of yacc.c */
+#line 185 "parser.y"
+ { (yyval.string) = NULL; }
+ break;
+
+ case 5:
+
+/* Line 1455 of yacc.c */
+#line 188 "parser.y"
+ {
+ LOC_MERGE((yylsp[(1) - (6)]), (yylsp[(1) - (6)]), (yylsp[(5) - (6)]));
+ (yyval.term) = make_bind((yyvsp[(2) - (6)].string), (yyvsp[(3) - (6)].term), (yyvsp[(5) - (6)].term), (yyvsp[(6) - (6)].term), &(yylsp[(1) - (6)]));
+ }
+ break;
+
+ case 6:
+
+/* Line 1455 of yacc.c */
+#line 193 "parser.y"
+ {
+ LOC_MERGE((yylsp[(1) - (5)]), (yylsp[(1) - (5)]), (yylsp[(4) - (5)]));
+ (yyval.term) = make_bind_rec((yyvsp[(2) - (5)].string), (yyvsp[(4) - (5)].term), (yyvsp[(5) - (5)].term), &(yylsp[(1) - (5)]));
+ }
+ break;
+
+ case 7:
+
+/* Line 1455 of yacc.c */
+#line 198 "parser.y"
+ {
+ LOC_MERGE((yylsp[(1) - (5)]), (yylsp[(1) - (5)]), (yylsp[(4) - (5)]));
+ (yyval.term) = make_test((yyvsp[(2) - (5)].term), (yyvsp[(4) - (5)].term), TR_CHECK, (yyvsp[(5) - (5)].term), &(yylsp[(1) - (5)]));
+ }
+ break;
+
+ case 8:
+
+/* Line 1455 of yacc.c */
+#line 203 "parser.y"
+ {
+ LOC_MERGE((yylsp[(1) - (5)]), (yylsp[(1) - (5)]), (yylsp[(4) - (5)]));
+ (yyval.term) = make_test((yyvsp[(2) - (5)].term), NULL, (yyvsp[(4) - (5)].intval), (yyvsp[(5) - (5)].term), &(yylsp[(1) - (5)]));
+ }
+ break;
+
+ case 9:
+
+/* Line 1455 of yacc.c */
+#line 208 "parser.y"
+ { (yyval.term) = NULL; }
+ break;
+
+ case 10:
+
+/* Line 1455 of yacc.c */
+#line 213 "parser.y"
+ { (yyval.term) = make_get_test((yyvsp[(1) - (3)].term), (yyvsp[(3) - (3)].term), &(yyloc)); }
+ break;
+
+ case 11:
+
+/* Line 1455 of yacc.c */
+#line 215 "parser.y"
+ { (yyval.term) = make_put_test((yyvsp[(1) - (5)].term), (yyvsp[(3) - (5)].term), (yyvsp[(5) - (5)].term), &(yyloc)); }
+ break;
+
+ case 12:
+
+/* Line 1455 of yacc.c */
+#line 218 "parser.y"
+ { (yyval.intval) = TR_PRINT; }
+ break;
+
+ case 13:
+
+/* Line 1455 of yacc.c */
+#line 220 "parser.y"
+ { (yyval.intval) = TR_EXN; }
+ break;
+
+ case 14:
+
+/* Line 1455 of yacc.c */
+#line 224 "parser.y"
+ {
+ LOC_MERGE((yylsp[(1) - (7)]), (yylsp[(1) - (7)]), (yylsp[(6) - (7)]));
+ (yyval.term) = make_let((yyvsp[(2) - (7)].string), (yyvsp[(3) - (7)].term), (yyvsp[(5) - (7)].term), (yyvsp[(7) - (7)].term), &(yylsp[(1) - (7)]));
+ }
+ break;
+
+ case 16:
+
+/* Line 1455 of yacc.c */
+#line 231 "parser.y"
+ { (yyval.term) = make_binop(A_COMPOSE, (yyvsp[(1) - (3)].term), (yyvsp[(3) - (3)].term), &(yyloc)); }
+ break;
+
+ case 17:
+
+/* Line 1455 of yacc.c */
+#line 233 "parser.y"
+ { (yyval.term) = (yyvsp[(1) - (1)].term); }
+ break;
+
+ case 18:
+
+/* Line 1455 of yacc.c */
+#line 236 "parser.y"
+ { (yyval.term) = make_binop(A_UNION, (yyvsp[(1) - (3)].term), (yyvsp[(3) - (3)].term), &(yyloc)); }
+ break;
+
+ case 19:
+
+/* Line 1455 of yacc.c */
+#line 238 "parser.y"
+ { (yyval.term) = (yyvsp[(1) - (1)].term); }
+ break;
+
+ case 20:
+
+/* Line 1455 of yacc.c */
+#line 240 "parser.y"
+ { (yyval.term) = make_tree_value((yyvsp[(1) - (1)].tree), &(yylsp[(1) - (1)])); }
+ break;
+
+ case 21:
+
+/* Line 1455 of yacc.c */
+#line 243 "parser.y"
+ { (yyval.term) = make_binop(A_MINUS, (yyvsp[(1) - (3)].term), (yyvsp[(3) - (3)].term), &(yyloc)); }
+ break;
+
+ case 22:
+
+/* Line 1455 of yacc.c */
+#line 245 "parser.y"
+ { (yyval.term) = (yyvsp[(1) - (1)].term); }
+ break;
+
+ case 23:
+
+/* Line 1455 of yacc.c */
+#line 248 "parser.y"
+ { (yyval.term) = make_binop(A_CONCAT, (yyvsp[(1) - (3)].term), (yyvsp[(3) - (3)].term), &(yyloc)); }
+ break;
+
+ case 24:
+
+/* Line 1455 of yacc.c */
+#line 250 "parser.y"
+ { (yyval.term) = (yyvsp[(1) - (1)].term); }
+ break;
+
+ case 25:
+
+/* Line 1455 of yacc.c */
+#line 253 "parser.y"
+ { (yyval.term) = make_binop(A_APP, (yyvsp[(1) - (2)].term), (yyvsp[(2) - (2)].term), &(yyloc)); }
+ break;
+
+ case 26:
+
+/* Line 1455 of yacc.c */
+#line 255 "parser.y"
+ { (yyval.term) = (yyvsp[(1) - (1)].term); }
+ break;
+
+ case 27:
+
+/* Line 1455 of yacc.c */
+#line 258 "parser.y"
+ { (yyval.term) = make_ident((yyvsp[(1) - (1)].string), &(yylsp[(1) - (1)])); }
+ break;
+
+ case 28:
+
+/* Line 1455 of yacc.c */
+#line 260 "parser.y"
+ { (yyval.term) = make_string_term((yyvsp[(1) - (1)].string), &(yylsp[(1) - (1)])); }
+ break;
+
+ case 29:
+
+/* Line 1455 of yacc.c */
+#line 262 "parser.y"
+ { (yyval.term) = make_regexp_term((yyvsp[(1) - (1)].regexp).pattern, (yyvsp[(1) - (1)].regexp).nocase, &(yylsp[(1) - (1)])); }
+ break;
+
+ case 30:
+
+/* Line 1455 of yacc.c */
+#line 264 "parser.y"
+ { (yyval.term) = (yyvsp[(2) - (3)].term); }
+ break;
+
+ case 31:
+
+/* Line 1455 of yacc.c */
+#line 266 "parser.y"
+ { (yyval.term) = make_unop(A_BRACKET, (yyvsp[(2) - (3)].term), &(yyloc)); }
+ break;
+
+ case 32:
+
+/* Line 1455 of yacc.c */
+#line 268 "parser.y"
+ { (yyval.term) = make_unit_term(&(yyloc)); }
+ break;
+
+ case 33:
+
+/* Line 1455 of yacc.c */
+#line 271 "parser.y"
+ { (yyval.term) = make_rep((yyvsp[(1) - (2)].term), (yyvsp[(2) - (2)].quant), &(yyloc)); }
+ break;
+
+ case 34:
+
+/* Line 1455 of yacc.c */
+#line 273 "parser.y"
+ { (yyval.term) = (yyvsp[(1) - (1)].term); }
+ break;
+
+ case 35:
+
+/* Line 1455 of yacc.c */
+#line 276 "parser.y"
+ { (yyval.quant) = Q_STAR; }
+ break;
+
+ case 36:
+
+/* Line 1455 of yacc.c */
+#line 278 "parser.y"
+ { (yyval.quant) = Q_PLUS; }
+ break;
+
+ case 37:
+
+/* Line 1455 of yacc.c */
+#line 280 "parser.y"
+ { (yyval.quant) = Q_MAYBE; }
+ break;
+
+ case 38:
+
+/* Line 1455 of yacc.c */
+#line 283 "parser.y"
+ { (yyval.string) = (yyvsp[(1) - (1)].string); }
+ break;
+
+ case 39:
+
+/* Line 1455 of yacc.c */
+#line 285 "parser.y"
+ { (yyval.string) = (yyvsp[(1) - (1)].string); }
+ break;
+
+ case 40:
+
+/* Line 1455 of yacc.c */
+#line 287 "parser.y"
+ { (yyval.string) = strdup("get"); }
+ break;
+
+ case 41:
+
+/* Line 1455 of yacc.c */
+#line 289 "parser.y"
+ { (yyval.string) = strdup("put"); }
+ break;
+
+ case 42:
+
+/* Line 1455 of yacc.c */
+#line 292 "parser.y"
+ { (yyval.term) = (yyvsp[(2) - (2)].term); list_cons((yyval.term), (yyvsp[(1) - (2)].term)); }
+ break;
+
+ case 43:
+
+/* Line 1455 of yacc.c */
+#line 294 "parser.y"
+ { (yyval.term) = NULL; }
+ break;
+
+ case 44:
+
+/* Line 1455 of yacc.c */
+#line 297 "parser.y"
+ { (yyval.term) = make_param((yyvsp[(2) - (5)].string), (yyvsp[(4) - (5)].type), clone_info(&(yylsp[(1) - (5)]))); }
+ break;
+
+ case 45:
+
+/* Line 1455 of yacc.c */
+#line 300 "parser.y"
+ { (yyval.string) = (yyvsp[(1) - (1)].string); }
+ break;
+
+ case 46:
+
+/* Line 1455 of yacc.c */
+#line 302 "parser.y"
+ { (yyval.string) = strdup("get"); }
+ break;
+
+ case 47:
+
+/* Line 1455 of yacc.c */
+#line 304 "parser.y"
+ { (yyval.string) = strdup("put"); }
+ break;
+
+ case 48:
+
+/* Line 1455 of yacc.c */
+#line 307 "parser.y"
+ { (yyval.type) = make_arrow_type((yyvsp[(1) - (3)].type), (yyvsp[(3) - (3)].type)); }
+ break;
+
+ case 49:
+
+/* Line 1455 of yacc.c */
+#line 309 "parser.y"
+ { (yyval.type) = (yyvsp[(1) - (1)].type); }
+ break;
+
+ case 50:
+
+/* Line 1455 of yacc.c */
+#line 312 "parser.y"
+ { (yyval.type) = make_base_type(T_STRING); }
+ break;
+
+ case 51:
+
+/* Line 1455 of yacc.c */
+#line 314 "parser.y"
+ { (yyval.type) = make_base_type(T_REGEXP); }
+ break;
+
+ case 52:
+
+/* Line 1455 of yacc.c */
+#line 316 "parser.y"
+ { (yyval.type) = make_base_type(T_LENS); }
+ break;
+
+ case 53:
+
+/* Line 1455 of yacc.c */
+#line 318 "parser.y"
+ { (yyval.type) = (yyvsp[(2) - (3)].type); }
+ break;
+
+ case 54:
+
+/* Line 1455 of yacc.c */
+#line 321 "parser.y"
+ { (yyval.tree) = tree_concat((yyvsp[(1) - (4)].tree), (yyvsp[(3) - (4)].tree)); }
+ break;
+
+ case 55:
+
+/* Line 1455 of yacc.c */
+#line 323 "parser.y"
+ { (yyval.tree) = tree_concat((yyvsp[(2) - (3)].tree), NULL); }
+ break;
+
+ case 56:
+
+/* Line 1455 of yacc.c */
+#line 326 "parser.y"
+ {
+ (yyval.tree) = tree_concat((yyvsp[(1) - (4)].tree), (yyvsp[(3) - (4)].tree));
+ }
+ break;
+
+ case 57:
+
+/* Line 1455 of yacc.c */
+#line 330 "parser.y"
+ { (yyval.tree) = NULL; }
+ break;
+
+ case 58:
+
+/* Line 1455 of yacc.c */
+#line 333 "parser.y"
+ {
+ (yyval.tree) = make_tree((yyvsp[(1) - (2)].string), NULL, NULL, (yyvsp[(2) - (2)].tree));
+ }
+ break;
+
+ case 59:
+
+/* Line 1455 of yacc.c */
+#line 337 "parser.y"
+ {
+ (yyval.tree) = make_tree((yyvsp[(1) - (4)].string), (yyvsp[(3) - (4)].string), NULL, (yyvsp[(4) - (4)].tree));
+ }
+ break;
+
+ case 61:
+
+/* Line 1455 of yacc.c */
+#line 342 "parser.y"
+ { (yyval.string) = NULL; }
+ break;
+
+
+
+/* Line 1455 of yacc.c */
+#line 2111 "parser.c"
+ default: break;
+ }
+ YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc);
+
+ YYPOPSTACK (yylen);
+ yylen = 0;
+ YY_STACK_PRINT (yyss, yyssp);
+
+ *++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. */
+
+ yyn = yyr1[yyn];
+
+ yystate = yypgoto[yyn - YYNTOKENS] + *yyssp;
+ if (0 <= yystate && yystate <= YYLAST && yycheck[yystate] == *yyssp)
+ yystate = yytable[yystate];
+ else
+ yystate = yydefgoto[yyn - YYNTOKENS];
+
+ goto yynewstate;
+
+
+/*------------------------------------.
+| yyerrlab -- here on detecting error |
+`------------------------------------*/
+yyerrlab:
+ /* If not already recovering from an error, report this error. */
+ if (!yyerrstatus)
+ {
+ ++yynerrs;
+#if ! YYERROR_VERBOSE
+ yyerror (&yylloc, term, scanner, YY_("syntax error"));
+#else
+ {
+ YYSIZE_T yysize = yysyntax_error (0, yystate, yychar);
+ if (yymsg_alloc < yysize && yymsg_alloc < YYSTACK_ALLOC_MAXIMUM)
+ {
+ YYSIZE_T yyalloc = 2 * yysize;
+ if (! (yysize <= yyalloc && yyalloc <= YYSTACK_ALLOC_MAXIMUM))
+ yyalloc = YYSTACK_ALLOC_MAXIMUM;
+ if (yymsg != yymsgbuf)
+ YYSTACK_FREE (yymsg);
+ yymsg = (char *) YYSTACK_ALLOC (yyalloc);
+ if (yymsg)
+ yymsg_alloc = yyalloc;
+ else
+ {
+ yymsg = yymsgbuf;
+ yymsg_alloc = sizeof yymsgbuf;
+ }
+ }
+
+ if (0 < yysize && yysize <= yymsg_alloc)
+ {
+ (void) yysyntax_error (yymsg, yystate, yychar);
+ yyerror (&yylloc, term, scanner, yymsg);
+ }
+ else
+ {
+ yyerror (&yylloc, term, scanner, YY_("syntax error"));
+ if (yysize != 0)
+ goto yyexhaustedlab;
+ }
+ }
+#endif
+ }
+
+ yyerror_range[0] = 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, term, scanner);
+ 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 like GCC when the user code never invokes
+ YYERROR and the label yyerrorlab therefore never appears in user
+ code. */
+ if (/*CONSTCOND*/ 0)
+ goto yyerrorlab;
+
+ yyerror_range[0] = yylsp[1-yylen];
+ /* Do not reclaim the symbols of the rule which 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. */
+
+ for (;;)
+ {
+ yyn = yypact[yystate];
+ if (yyn != YYPACT_NINF)
+ {
+ yyn += YYTERROR;
+ if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR)
+ {
+ yyn = yytable[yyn];
+ if (0 < yyn)
+ break;
+ }
+ }
+
+ /* Pop the current state because it cannot handle the error token. */
+ if (yyssp == yyss)
+ YYABORT;
+
+ yyerror_range[0] = *yylsp;
+ yydestruct ("Error: popping",
+ yystos[yystate], yyvsp, yylsp, term, scanner);
+ YYPOPSTACK (1);
+ yystate = *yyssp;
+ YY_STACK_PRINT (yyss, yyssp);
+ }
+
+ *++yyvsp = yylval;
+
+ yyerror_range[1] = yylloc;
+ /* Using YYLLOC is tempting, but would change the location of
+ the lookahead. YYLOC is available though. */
+ YYLLOC_DEFAULT (yyloc, (yyerror_range - 1), 2);
+ *++yylsp = yyloc;
+
+ /* Shift the error token. */
+ YY_SYMBOL_PRINT ("Shifting", yystos[yyn], yyvsp, yylsp);
+
+ yystate = yyn;
+ goto yynewstate;
+
+
+/*-------------------------------------.
+| yyacceptlab -- YYACCEPT comes here. |
+`-------------------------------------*/
+yyacceptlab:
+ yyresult = 0;
+ goto yyreturn;
+
+/*-----------------------------------.
+| yyabortlab -- YYABORT comes here. |
+`-----------------------------------*/
+yyabortlab:
+ yyresult = 1;
+ goto yyreturn;
+
+#if !defined(yyoverflow) || YYERROR_VERBOSE
+/*-------------------------------------------------.
+| yyexhaustedlab -- memory exhaustion comes here. |
+`-------------------------------------------------*/
+yyexhaustedlab:
+ yyerror (&yylloc, term, scanner, YY_("memory exhausted"));
+ yyresult = 2;
+ /* Fall through. */
+#endif
+
+yyreturn:
+ if (yychar != YYEMPTY)
+ yydestruct ("Cleanup: discarding lookahead",
+ yytoken, &yylval, &yylloc, term, scanner);
+ /* Do not reclaim the symbols of the rule which action triggered
+ this YYABORT or YYACCEPT. */
+ YYPOPSTACK (yylen);
+ YY_STACK_PRINT (yyss, yyssp);
+ while (yyssp != yyss)
+ {
+ yydestruct ("Cleanup: popping",
+ yystos[*yyssp], yyvsp, yylsp, term, scanner);
+ YYPOPSTACK (1);
+ }
+#ifndef yyoverflow
+ if (yyss != yyssa)
+ YYSTACK_FREE (yyss);
+#endif
+#if YYERROR_VERBOSE
+ if (yymsg != yymsgbuf)
+ YYSTACK_FREE (yymsg);
+#endif
+ /* Make sure YYID is used. */
+ return YYID (yyresult);
+}
+
+
+
+/* Line 1675 of yacc.c */
+#line 343 "parser.y"
+
+
+int augl_parse_file(struct augeas *aug, const char *name,
+ struct term **term) {
+ yyscan_t scanner;
+ struct state state;
+ struct string *sname = NULL;
+ struct info info;
+ int result = -1;
+ int r;
+
+ *term = NULL;
+
+ r = make_ref(sname);
+ ERR_NOMEM(r < 0, aug);
+
+ sname->str = strdup(name);
+ ERR_NOMEM(sname->str == NULL, aug);
+
+ MEMZERO(&info, 1);
+ info.ref = UINT_MAX;
+ info.filename = sname;
+ info.error = aug->error;
+
+ MEMZERO(&state, 1);
+ state.info = &info;
+ state.comment_depth = 0;
+
+ if (augl_init_lexer(&state, &scanner) < 0) {
+ augl_error(&info, term, NULL, "file not found");
+ goto error;
+ }
+
+ yydebug = getenv("YYDEBUG") != NULL;
+ r = augl_parse(term, scanner);
+ augl_close_lexer(scanner);
+ augl_lex_destroy(scanner);
+ if (r == 1) {
+ augl_error(&info, term, NULL, "syntax error");
+ goto error;
+ } else if (r == 2) {
+ augl_error(&info, term, NULL, "parser ran out of memory");
+ ERR_NOMEM(1, aug);
+ }
+ result = 0;
+
+ error:
+ unref(sname, string);
+ // free TERM
+ return result;
+}
+
+// FIXME: Nothing here checks for alloc errors.
+static struct info *clone_info(struct info *locp) {
+ struct info *info;
+ make_ref(info);
+ info->filename = ref(locp->filename);
+ info->first_line = locp->first_line;
+ info->first_column = locp->first_column;
+ info->last_line = locp->last_line;
+ info->last_column = locp->last_column;
+ info->error = locp->error;
+ return info;
+}
+
+static struct term *make_term_locp(enum term_tag tag, struct info *locp) {
+ struct info *info = clone_info(locp);
+ return make_term(tag, info);
+}
+
+static struct term *make_module(char *ident, char *autoload,
+ struct term *decls,
+ struct info *locp) {
+ struct term *term = make_term_locp(A_MODULE, locp);
+ term->mname = ident;
+ term->autoload = autoload;
+ term->decls = decls;
+ return term;
+}
+
+static struct term *make_bind(char *ident, struct term *params,
+ struct term *exp, struct term *decls,
+ struct info *locp) {
+ struct term *term = make_term_locp(A_BIND, locp);
+ if (params != NULL)
+ exp = build_func(params, exp);
+
+ term->bname = ident;
+ term->exp = exp;
+ list_cons(decls, term);
+ return decls;
+}
+
+static struct term *make_bind_rec(char *ident, struct term *exp,
+ struct term *decls, struct info *locp) {
+ /* Desugar let rec IDENT = EXP as
+ * let IDENT =
+ * let RLENS = (lns_make_rec) in
+ * lns_check_rec ((lambda IDENT: EXP) RLENS) RLENS
+ * where RLENS is a brandnew recursive lens.
+ *
+ * That only works since we know that 'let rec' is only defined for lenses,
+ * not general purposes functions, i.e. we know that IDENT has type 'lens'
+ *
+ * The point of all this is that we make it possible to put a recursive
+ * lens (which is a placeholder for the actual recursion) into arbitrary
+ * places in some bigger lens and then have LNS_CHECK_REC rattle through
+ * to do the special-purpose typechecking.
+ */
+ char *id;
+ struct info *info = exp->info;
+ struct term *lambda = NULL, *rlens = NULL;
+ struct term *app1 = NULL, *app2 = NULL, *app3 = NULL;
+
+ id = strdup(ident);
+ if (id == NULL) goto error;
+
+ lambda = make_param(id, make_base_type(T_LENS), ref(info));
+ if (lambda == NULL) goto error;
+ id = NULL;
+
+ build_func(lambda, exp);
+
+ rlens = make_term(A_VALUE, ref(exp->info));
+ if (rlens == NULL) goto error;
+ rlens->value = lns_make_rec(ref(exp->info));
+ if (rlens->value == NULL) goto error;
+ rlens->type = make_base_type(T_LENS);
+
+ app1 = make_app_term(lambda, rlens, ref(info));
+ if (app1 == NULL) goto error;
+
+ id = strdup(LNS_CHECK_REC_NAME);
+ if (id == NULL) goto error;
+ app2 = make_app_ident(id, app1, ref(info));
+ if (app2 == NULL) goto error;
+ id = NULL;
+
+ app3 = make_app_term(app2, ref(rlens), ref(info));
+ if (app3 == NULL) goto error;
+
+ return make_bind(ident, NULL, app3, decls, locp);
+
+ error:
+ free(id);
+ unref(lambda, term);
+ unref(rlens, term);
+ unref(app1, term);
+ unref(app2, term);
+ unref(app3, term);
+ return NULL;
+}
+
+static struct term *make_let(char *ident, struct term *params,
+ struct term *exp, struct term *body,
+ struct info *locp) {
+ /* let f (x:string) = "f " . x in
+ f "a" . f "b" */
+ /* (lambda f: f "a" . f "b") (lambda x: "f " . x) */
+ /* (lambda IDENT: BODY) (lambda PARAMS: EXP) */
+ /* Desugar as (lambda IDENT: BODY) (lambda PARAMS: EXP) */
+ struct term *term = make_term_locp(A_LET, locp);
+ struct term *p = make_param(ident, NULL, ref(term->info));
+ term->left = build_func(p, body);
+ if (params != NULL)
+ term->right = build_func(params, exp);
+ else
+ term->right = exp;
+ return term;
+}
+
+static struct term *make_binop(enum term_tag tag,
+ struct term *left, struct term *right,
+ struct info *locp) {
+ assert(tag == A_COMPOSE || tag == A_CONCAT
+ || tag == A_UNION || tag == A_APP || tag == A_MINUS);
+ struct term *term = make_term_locp(tag, locp);
+ term->left = left;
+ term->right = right;
+ return term;
+}
+
+static struct term *make_unop(enum term_tag tag, struct term *exp,
+ struct info *locp) {
+ assert(tag == A_BRACKET);
+ struct term *term = make_term_locp(tag, locp);
+ term->brexp = exp;
+ return term;
+}
+
+static struct term *make_ident(char *qname, struct info *locp) {
+ struct term *term = make_term_locp(A_IDENT, locp);
+ term->ident = make_string(qname);
+ return term;
+}
+
+static struct term *make_unit_term(struct info *locp) {
+ struct term *term = make_term_locp(A_VALUE, locp);
+ term->value = make_unit(ref(term->info));
+ return term;
+}
+
+static struct term *make_string_term(char *value, struct info *locp) {
+ struct term *term = make_term_locp(A_VALUE, locp);
+ term->value = make_value(V_STRING, ref(term->info));
+ term->value->string = make_string(value);
+ return term;
+}
+
+static struct term *make_regexp_term(char *pattern, int nocase,
+ struct info *locp) {
+ struct term *term = make_term_locp(A_VALUE, locp);
+ term->value = make_value(V_REGEXP, ref(term->info));
+ term->value->regexp = make_regexp(term->info, pattern, nocase);
+ return term;
+}
+
+static struct term *make_rep(struct term *exp, enum quant_tag quant,
+ struct info *locp) {
+ struct term *term = make_term_locp(A_REP, locp);
+ term->quant = quant;
+ term->exp = exp;
+ return term;
+}
+
+static struct term *make_get_test(struct term *lens, struct term *arg,
+ struct info *locp) {
+ /* Return a term for "get" LENS ARG */
+ struct info *info = clone_info(locp);
+ struct term *term = make_app_ident(strdup("get"), lens, info);
+ term = make_app_term(term, arg, ref(info));
+ return term;
+}
+
+static struct term *make_put_test(struct term *lens, struct term *arg,
+ struct term *cmds, struct info *locp) {
+ /* Return a term for "put" LENS (CMDS ("get" LENS ARG)) ARG */
+ struct term *term = make_get_test(lens, arg, locp);
+ term = make_app_term(cmds, term, ref(term->info));
+ struct term *put = make_app_ident(strdup("put"), ref(lens), ref(term->info));
+ put = make_app_term(put, term, ref(term->info));
+ put = make_app_term(put, ref(arg), ref(term->info));
+ return put;
+}
+
+static struct term *make_test(struct term *test, struct term *result,
+ enum test_result_tag tr_tag,
+ struct term *decls, struct info *locp) {
+ struct term *term = make_term_locp(A_TEST, locp);
+ term->tr_tag = tr_tag;
+ term->test = test;
+ term->result = result;
+ term->next = decls;
+ return term;
+}
+
+static struct term *make_tree_value(struct tree *tree, struct info *locp) {
+ struct term *term = make_term_locp(A_VALUE, locp);
+ struct value *value = make_value(V_TREE, ref(term->info));
+ value->origin = make_tree_origin(tree);
+ term->value = value;
+ return term;
+}
+
+static struct tree *tree_concat(struct tree *t1, struct tree *t2) {
+ if (t2 != NULL)
+ list_append(t1, t2);
+ return t1;
+}
+
+void augl_error(struct info *locp,
+ struct term **term,
+ yyscan_t scanner,
+ const char *s) {
+ struct info info;
+ struct string string;
+ MEMZERO(&info, 1);
+ info.ref = string.ref = UINT_MAX;
+ info.filename = &string;
+
+ if (locp != NULL) {
+ info.first_line = locp->first_line;
+ info.first_column = locp->first_column;
+ info.last_line = locp->last_line;
+ info.last_column = locp->last_column;
+ info.filename->str = locp->filename->str;
+ info.error = locp->error;
+ } else if (scanner != NULL) {
+ info.first_line = augl_get_lineno(scanner);
+ info.first_column = augl_get_column(scanner);
+ info.last_line = augl_get_lineno(scanner);
+ info.last_column = augl_get_column(scanner);
+ info.filename = augl_get_info(scanner)->filename;
+ info.error = augl_get_info(scanner)->error;
+ } else if (*term != NULL && (*term)->info != NULL) {
+ memcpy(&info, (*term)->info, sizeof(info));
+ } else {
+ info.first_line = info.last_line = 0;
+ info.first_column = info.last_column = 0;
+ }
+ syntax_error(&info, "%s", s);
+}
diff --git a/libraries/cmake/source/augeas/generated/linux/x86_64/code/parser.h b/libraries/cmake/source/augeas/generated/linux/x86_64/code/parser.h
new file mode 100644
index 00000000000..9c1c5ce0c66
--- /dev/null
+++ b/libraries/cmake/source/augeas/generated/linux/x86_64/code/parser.h
@@ -0,0 +1,148 @@
+
+/* A Bison parser, made by GNU Bison 2.4.1. */
+
+/* Skeleton interface for Bison's Yacc-like parsers in C
+
+ Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006
+ 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. */
+
+
+/* Tokens. */
+#ifndef YYTOKENTYPE
+# define YYTOKENTYPE
+ /* Put the tokens into the symbol table, so that GDB and other debuggers
+ know about them. */
+ enum yytokentype {
+ DQUOTED = 258,
+ REGEXP = 259,
+ LIDENT = 260,
+ UIDENT = 261,
+ QIDENT = 262,
+ ARROW = 263,
+ KW_MODULE = 264,
+ KW_AUTOLOAD = 265,
+ KW_LET = 266,
+ KW_LET_REC = 267,
+ KW_IN = 268,
+ KW_STRING = 269,
+ KW_REGEXP = 270,
+ KW_LENS = 271,
+ KW_TEST = 272,
+ KW_GET = 273,
+ KW_PUT = 274,
+ KW_AFTER = 275
+ };
+#endif
+/* Tokens. */
+#define DQUOTED 258
+#define REGEXP 259
+#define LIDENT 260
+#define UIDENT 261
+#define QIDENT 262
+#define ARROW 263
+#define KW_MODULE 264
+#define KW_AUTOLOAD 265
+#define KW_LET 266
+#define KW_LET_REC 267
+#define KW_IN 268
+#define KW_STRING 269
+#define KW_REGEXP 270
+#define KW_LENS 271
+#define KW_TEST 272
+#define KW_GET 273
+#define KW_PUT 274
+#define KW_AFTER 275
+
+
+
+
+#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
+typedef union YYSTYPE
+{
+
+/* Line 1676 of yacc.c */
+#line 89 "parser.y"
+
+ struct term *term;
+ struct type *type;
+ struct ident *ident;
+ struct tree *tree;
+ char *string;
+ struct {
+ int nocase;
+ char *pattern;
+ } regexp;
+ int intval;
+ enum quant_tag quant;
+
+
+
+/* Line 1676 of yacc.c */
+#line 108 "parser.h"
+} YYSTYPE;
+# define YYSTYPE_IS_TRIVIAL 1
+# define yystype YYSTYPE /* obsolescent; will be withdrawn */
+# define YYSTYPE_IS_DECLARED 1
+#endif
+
+
+
+#if ! defined YYLTYPE && ! defined YYLTYPE_IS_DECLARED
+typedef struct YYLTYPE
+{
+ int first_line;
+ int first_column;
+ int last_line;
+ int last_column;
+} YYLTYPE;
+# define yyltype YYLTYPE /* obsolescent; will be withdrawn */
+# define YYLTYPE_IS_DECLARED 1
+# define YYLTYPE_IS_TRIVIAL 1
+#endif
+
+
+
+/* "%code provides" blocks. */
+
+/* Line 1676 of yacc.c */
+#line 46 "parser.y"
+
+#include "info.h"
+
+/* Track custom scanner state */
+struct state {
+ struct info *info;
+ unsigned int comment_depth;
+};
+
+
+
+
+/* Line 1676 of yacc.c */
+#line 149 "parser.h"
\ No newline at end of file
diff --git a/libraries/cmake/source/augeas/generated/linux/x86_64/config/config.h b/libraries/cmake/source/augeas/generated/linux/x86_64/config/config.h
new file mode 100644
index 00000000000..412fea1cdcf
--- /dev/null
+++ b/libraries/cmake/source/augeas/generated/linux/x86_64/config/config.h
@@ -0,0 +1,1573 @@
+/* config.h. Generated from config.h.in by configure. */
+/* config.h.in. Generated from configure.ac by autoheader. */
+
+/* Define if building universal (internal helper macro) */
+/* #undef AC_APPLE_UNIVERSAL_BUILD */
+
+/* Define to the number of bits in type 'ptrdiff_t'. */
+/* #undef BITSIZEOF_PTRDIFF_T */
+
+/* Define to the number of bits in type 'sig_atomic_t'. */
+/* #undef BITSIZEOF_SIG_ATOMIC_T */
+
+/* Define to the number of bits in type 'size_t'. */
+/* #undef BITSIZEOF_SIZE_T */
+
+/* Define to the number of bits in type 'wchar_t'. */
+/* #undef BITSIZEOF_WCHAR_T */
+
+/* Define to the number of bits in type 'wint_t'. */
+/* #undef BITSIZEOF_WINT_T */
+
+/* Define to one of '_getb67', 'GETB67', 'getb67' for Cray-2 and Cray-YMP
+ systems. This function is required for 'alloca.c' support on those systems.
+ */
+/* #undef CRAY_STACKSEG_END */
+
+/* Define to 1 if using 'alloca.c'. */
+/* #undef C_ALLOCA */
+
+/* Define to 1 if the C locale may have encoding errors. */
+#define C_LOCALE_MAYBE_EILSEQ 1
+
+/* Define as the bit index in the word where to find bit 0 of the exponent of
+ 'double'. */
+#define DBL_EXPBIT0_BIT 20
+
+/* Define as the word index where to find the exponent of 'double'. */
+#define DBL_EXPBIT0_WORD 1
+
+/* Define to 1 if // is a file system root distinct from /. */
+/* #undef DOUBLE_SLASH_IS_DISTINCT_ROOT */
+
+/* whether debugging is enabled */
+#define ENABLE_DEBUG 1
+
+/* Define this to 1 if F_DUPFD behavior does not match POSIX */
+/* #undef FCNTL_DUPFD_BUGGY */
+
+/* Define to nothing if C supports flexible array members, and to 1 if it does
+ not. That way, with a declaration like 'struct s { int n; double
+ d[FLEXIBLE_ARRAY_MEMBER]; };', the struct hack can be used with pre-C99
+ compilers. When computing the size of such an object, don't use 'sizeof
+ (struct s)' as it overestimates the size. Use 'offsetof (struct s, d)'
+ instead. Don't use 'offsetof (struct s, d[0])', as this doesn't work with
+ MSVC and with C++ compilers. */
+#define FLEXIBLE_ARRAY_MEMBER /**/
+
+/* Enable compile-time and run-time bounds-checking, and some warnings,
+ without upsetting newer glibc. */
+ #if !defined _FORTIFY_SOURCE && defined __OPTIMIZE__ && __OPTIMIZE__
+ # define _FORTIFY_SOURCE 2
+ #endif
+
+
+/* Define to 1 if mkdir mistakenly creates a directory given with a trailing
+ dot component. */
+/* #undef FUNC_MKDIR_DOT_BUG */
+
+/* Define to 1 if nl_langinfo (YESEXPR) returns a non-empty string. */
+#define FUNC_NL_LANGINFO_YESEXPR_WORKS 1
+
+/* Define to 1 if realpath() can malloc memory, always gives an absolute path,
+ and handles trailing slash correctly. */
+#define FUNC_REALPATH_WORKS 1
+
+/* Define if gettimeofday clobbers the localtime buffer. */
+/* #undef GETTIMEOFDAY_CLOBBERS_LOCALTIME */
+
+/* Define this to 'void' or 'struct timezone' to match the system's
+ declaration of the second argument to gettimeofday. */
+#define GETTIMEOFDAY_TIMEZONE struct timezone
+
+/* Define to a C preprocessor expression that evaluates to 1 or 0, depending
+ whether the gnulib module canonicalize-lgpl shall be considered present. */
+#define GNULIB_CANONICALIZE_LGPL 1
+
+/* Define to a C preprocessor expression that evaluates to 1 or 0, depending
+ whether the gnulib module fscanf shall be considered present. */
+#define GNULIB_FSCANF 1
+
+/* Define to a C preprocessor expression that evaluates to 1 or 0, depending
+ whether the gnulib module lock shall be considered present. */
+#define GNULIB_LOCK 1
+
+/* Define to a C preprocessor expression that evaluates to 1 or 0, depending
+ whether the gnulib module msvc-nothrow shall be considered present. */
+#define GNULIB_MSVC_NOTHROW IN_AUGEAS_GNULIB_TESTS
+
+/* Define to 1 if printf and friends should be labeled with attribute
+ "__gnu_printf__" instead of "__printf__" */
+/* #undef GNULIB_PRINTF_ATTRIBUTE_FLAVOR_GNU */
+
+/* Define to a C preprocessor expression that evaluates to 1 or 0, depending
+ whether the gnulib module scanf shall be considered present. */
+#define GNULIB_SCANF 1
+
+/* Define to a C preprocessor expression that evaluates to 1 or 0, depending
+ whether the gnulib module strerror shall be considered present. */
+#define GNULIB_STRERROR IN_AUGEAS_GNULIB_TESTS
+
+/* Define to a C preprocessor expression that evaluates to 1 or 0, depending
+ whether the gnulib module strerror_r-posix shall be considered present. */
+#define GNULIB_STRERROR_R_POSIX IN_AUGEAS_GNULIB_TESTS
+
+/* Define to 1 when the gnulib module accept should be tested. */
+#define GNULIB_TEST_ACCEPT 1
+
+/* Define to 1 when the gnulib module bind should be tested. */
+#define GNULIB_TEST_BIND 1
+
+/* Define to 1 when the gnulib module btowc should be tested. */
+#define GNULIB_TEST_BTOWC 1
+
+/* Define to 1 when the gnulib module canonicalize_file_name should be tested.
+ */
+#define GNULIB_TEST_CANONICALIZE_FILE_NAME 1
+
+/* Define to 1 when the gnulib module cloexec should be tested. */
+#define GNULIB_TEST_CLOEXEC 1
+
+/* Define to 1 when the gnulib module close should be tested. */
+#define GNULIB_TEST_CLOSE 1
+
+/* Define to 1 when the gnulib module connect should be tested. */
+#define GNULIB_TEST_CONNECT 1
+
+/* Define to 1 when the gnulib module dup2 should be tested. */
+#define GNULIB_TEST_DUP2 1
+
+/* Define to 1 when the gnulib module environ should be tested. */
+#define GNULIB_TEST_ENVIRON 1
+
+/* Define to 1 when the gnulib module fcntl should be tested. */
+#define GNULIB_TEST_FCNTL 1
+
+/* Define to 1 when the gnulib module fdopen should be tested. */
+#define GNULIB_TEST_FDOPEN 1
+
+/* Define to 1 when the gnulib module fnmatch should be tested. */
+#define GNULIB_TEST_FNMATCH 1
+
+/* Define to 1 when the gnulib module fstat should be tested. */
+#define GNULIB_TEST_FSTAT 1
+
+/* Define to 1 when the gnulib module ftruncate should be tested. */
+#define GNULIB_TEST_FTRUNCATE 1
+
+/* Define to 1 when the gnulib module getcwd should be tested. */
+#define GNULIB_TEST_GETCWD 1
+
+/* Define to 1 when the gnulib module getdelim should be tested. */
+#define GNULIB_TEST_GETDELIM 1
+
+/* Define to 1 when the gnulib module getdtablesize should be tested. */
+#define GNULIB_TEST_GETDTABLESIZE 1
+
+/* Define to 1 when the gnulib module getline should be tested. */
+#define GNULIB_TEST_GETLINE 1
+
+/* Define to 1 when the gnulib module getpagesize should be tested. */
+#define GNULIB_TEST_GETPAGESIZE 1
+
+/* Define to 1 when the gnulib module gettimeofday should be tested. */
+#define GNULIB_TEST_GETTIMEOFDAY 1
+
+/* Define to 1 when the gnulib module ioctl should be tested. */
+#define GNULIB_TEST_IOCTL 1
+
+/* Define to 1 when the gnulib module listen should be tested. */
+#define GNULIB_TEST_LISTEN 1
+
+/* Define to 1 when the gnulib module localeconv should be tested. */
+#define GNULIB_TEST_LOCALECONV 1
+
+/* Define to 1 when the gnulib module localename should be tested. */
+#define GNULIB_TEST_LOCALENAME 1
+
+/* Define to 1 when the gnulib module lstat should be tested. */
+#define GNULIB_TEST_LSTAT 1
+
+/* Define to 1 when the gnulib module malloc-posix should be tested. */
+#define GNULIB_TEST_MALLOC_POSIX 1
+
+/* Define to 1 when the gnulib module mbrtowc should be tested. */
+#define GNULIB_TEST_MBRTOWC 1
+
+/* Define to 1 when the gnulib module mbsinit should be tested. */
+#define GNULIB_TEST_MBSINIT 1
+
+/* Define to 1 when the gnulib module mbsrtowcs should be tested. */
+#define GNULIB_TEST_MBSRTOWCS 1
+
+/* Define to 1 when the gnulib module mbtowc should be tested. */
+#define GNULIB_TEST_MBTOWC 1
+
+/* Define to 1 when the gnulib module memchr should be tested. */
+#define GNULIB_TEST_MEMCHR 1
+
+/* Define to 1 when the gnulib module mempcpy should be tested. */
+#define GNULIB_TEST_MEMPCPY 1
+
+/* Define to 1 when the gnulib module mkstemp should be tested. */
+#define GNULIB_TEST_MKSTEMP 1
+
+/* Define to 1 when the gnulib module nanosleep should be tested. */
+#define GNULIB_TEST_NANOSLEEP 1
+
+/* Define to 1 when the gnulib module nl_langinfo should be tested. */
+#define GNULIB_TEST_NL_LANGINFO 1
+
+/* Define to 1 when the gnulib module open should be tested. */
+#define GNULIB_TEST_OPEN 1
+
+/* Define to 1 when the gnulib module perror should be tested. */
+#define GNULIB_TEST_PERROR 1
+
+/* Define to 1 when the gnulib module pipe should be tested. */
+#define GNULIB_TEST_PIPE 1
+
+/* Define to 1 when the gnulib module pthread_sigmask should be tested. */
+#define GNULIB_TEST_PTHREAD_SIGMASK 1
+
+/* Define to 1 when the gnulib module putenv should be tested. */
+#define GNULIB_TEST_PUTENV 1
+
+/* Define to 1 when the gnulib module raise should be tested. */
+#define GNULIB_TEST_RAISE 1
+
+/* Define to 1 when the gnulib module rawmemchr should be tested. */
+#define GNULIB_TEST_RAWMEMCHR 1
+
+/* Define to 1 when the gnulib module readlink should be tested. */
+#define GNULIB_TEST_READLINK 1
+
+/* Define to 1 when the gnulib module realpath should be tested. */
+#define GNULIB_TEST_REALPATH 1
+
+/* Define to 1 when the gnulib module select should be tested. */
+#define GNULIB_TEST_SELECT 1
+
+/* Define to 1 when the gnulib module setenv should be tested. */
+#define GNULIB_TEST_SETENV 1
+
+/* Define to 1 when the gnulib module setlocale should be tested. */
+#define GNULIB_TEST_SETLOCALE 1
+
+/* Define to 1 when the gnulib module setsockopt should be tested. */
+#define GNULIB_TEST_SETSOCKOPT 1
+
+/* Define to 1 when the gnulib module sigaction should be tested. */
+#define GNULIB_TEST_SIGACTION 1
+
+/* Define to 1 when the gnulib module sigprocmask should be tested. */
+#define GNULIB_TEST_SIGPROCMASK 1
+
+/* Define to 1 when the gnulib module sleep should be tested. */
+#define GNULIB_TEST_SLEEP 1
+
+/* Define to 1 when the gnulib module socket should be tested. */
+#define GNULIB_TEST_SOCKET 1
+
+/* Define to 1 when the gnulib module stat should be tested. */
+#define GNULIB_TEST_STAT 1
+
+/* Define to 1 when the gnulib module stpcpy should be tested. */
+#define GNULIB_TEST_STPCPY 1
+
+/* Define to 1 when the gnulib module stpncpy should be tested. */
+#define GNULIB_TEST_STPNCPY 1
+
+/* Define to 1 when the gnulib module strchrnul should be tested. */
+#define GNULIB_TEST_STRCHRNUL 1
+
+/* Define to 1 when the gnulib module strerror should be tested. */
+#define GNULIB_TEST_STRERROR 1
+
+/* Define to 1 when the gnulib module strerror_r should be tested. */
+#define GNULIB_TEST_STRERROR_R 1
+
+/* Define to 1 when the gnulib module strndup should be tested. */
+#define GNULIB_TEST_STRNDUP 1
+
+/* Define to 1 when the gnulib module strnlen should be tested. */
+#define GNULIB_TEST_STRNLEN 1
+
+/* Define to 1 when the gnulib module strstr should be tested. */
+#define GNULIB_TEST_STRSTR 1
+
+/* Define to 1 when the gnulib module symlink should be tested. */
+#define GNULIB_TEST_SYMLINK 1
+
+/* Define to 1 when the gnulib module unsetenv should be tested. */
+#define GNULIB_TEST_UNSETENV 1
+
+/* Define to 1 when the gnulib module usleep should be tested. */
+#define GNULIB_TEST_USLEEP 1
+
+/* Define to 1 when the gnulib module vasprintf should be tested. */
+#define GNULIB_TEST_VASPRINTF 1
+
+/* Define to 1 when the gnulib module wcrtomb should be tested. */
+#define GNULIB_TEST_WCRTOMB 1
+
+/* Define to 1 when the gnulib module wctob should be tested. */
+#define GNULIB_TEST_WCTOB 1
+
+/* Define to 1 when the gnulib module wctomb should be tested. */
+#define GNULIB_TEST_WCTOMB 1
+
+/* Define to 1 if you have 'alloca' after including , a header that
+ may be supplied by this distribution. */
+#define HAVE_ALLOCA 1
+
+/* Define to 1 if you have and it should be used (not on Ultrix).
+ */
+#define HAVE_ALLOCA_H 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_ARGZ_H 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_ARPA_INET_H 1
+
+/* Define to 1 if you have the header file. */
+/* #undef HAVE_BP_SYM_H */
+
+/* Define to 1 if you have the `btowc' function. */
+#define HAVE_BTOWC 1
+
+/* Define to 1 if nanosleep mishandles large arguments. */
+#define HAVE_BUG_BIG_NANOSLEEP 1
+
+/* Define to 1 if you have the `canonicalize_file_name' function. */
+#define HAVE_CANONICALIZE_FILE_NAME 1
+
+/* Define to 1 if you have the `catgets' function. */
+#define HAVE_CATGETS 1
+
+/* Define to 1 if you have the Mac OS X function CFLocaleCopyCurrent in the
+ CoreFoundation framework. */
+/* #undef HAVE_CFLOCALECOPYCURRENT */
+
+/* Define to 1 if you have the Mac OS X function
+ CFLocaleCopyPreferredLanguages in the CoreFoundation framework. */
+/* #undef HAVE_CFLOCALECOPYPREFERREDLANGUAGES */
+
+/* Define to 1 if you have the Mac OS X function CFPreferencesCopyAppValue in
+ the CoreFoundation framework. */
+/* #undef HAVE_CFPREFERENCESCOPYAPPVALUE */
+
+/* Define to 1 if you have the `chsize' function. */
+/* #undef HAVE_CHSIZE */
+
+/* Define to 1 if you have the header file. */
+/* #undef HAVE_CRTDEFS_H */
+
+/* Define to 1 if you have the declaration of `alarm', and to 0 if you don't.
+ */
+#define HAVE_DECL_ALARM 1
+
+/* Define to 1 if you have the declaration of `getc_unlocked', and to 0 if you
+ don't. */
+/* #undef HAVE_DECL_GETC_UNLOCKED */
+
+/* Define to 1 if you have the declaration of `getdelim', and to 0 if you
+ don't. */
+#define HAVE_DECL_GETDELIM 1
+
+/* Define to 1 if you have the declaration of `getdtablesize', and to 0 if you
+ don't. */
+#define HAVE_DECL_GETDTABLESIZE 1
+
+/* Define to 1 if you have the declaration of `getline', and to 0 if you
+ don't. */
+#define HAVE_DECL_GETLINE 1
+
+/* Define to 1 if you have the declaration of `inet_pton', and to 0 if you
+ don't. */
+#define HAVE_DECL_INET_PTON 1
+
+/* Define to 1 if you have the declaration of `isblank', and to 0 if you
+ don't. */
+#define HAVE_DECL_ISBLANK 1
+
+/* Define to 1 if you have the declaration of `mbrtowc', and to 0 if you
+ don't. */
+/* #undef HAVE_DECL_MBRTOWC */
+
+/* Define to 1 if you have the declaration of `mbsinit', and to 0 if you
+ don't. */
+/* #undef HAVE_DECL_MBSINIT */
+
+/* Define to 1 if you have the declaration of `mbsrtowcs', and to 0 if you
+ don't. */
+/* #undef HAVE_DECL_MBSRTOWCS */
+
+/* Define to 1 if you have the declaration of `setenv', and to 0 if you don't.
+ */
+#define HAVE_DECL_SETENV 1
+
+/* Define to 1 if you have the declaration of `sleep', and to 0 if you don't.
+ */
+#define HAVE_DECL_SLEEP 1
+
+/* Define to 1 if you have the declaration of `stpncpy', and to 0 if you
+ don't. */
+#define HAVE_DECL_STPNCPY 1
+
+/* Define to 1 if you have the declaration of `strerror_r', and to 0 if you
+ don't. */
+#define HAVE_DECL_STRERROR_R 1
+
+/* Define to 1 if you have the declaration of `strndup', and to 0 if you
+ don't. */
+#define HAVE_DECL_STRNDUP 1
+
+/* Define to 1 if you have the declaration of `strnlen', and to 0 if you
+ don't. */
+#define HAVE_DECL_STRNLEN 1
+
+/* Define to 1 if you have the declaration of `towlower', and to 0 if you
+ don't. */
+/* #undef HAVE_DECL_TOWLOWER */
+
+/* Define to 1 if you have the declaration of `unsetenv', and to 0 if you
+ don't. */
+#define HAVE_DECL_UNSETENV 1
+
+/* Define to 1 if you have the declaration of `wcrtomb', and to 0 if you
+ don't. */
+/* #undef HAVE_DECL_WCRTOMB */
+
+/* Define to 1 if you have the declaration of `wctob', and to 0 if you don't.
+ */
+#define HAVE_DECL_WCTOB 1
+
+/* Define to 1 if you have the declaration of `_putenv', and to 0 if you
+ don't. */
+/* #undef HAVE_DECL__PUTENV */
+
+/* Define to 1 if you have the declaration of `_snprintf', and to 0 if you
+ don't. */
+#define HAVE_DECL__SNPRINTF 0
+
+/* Define to 1 if you have the header file. */
+#define HAVE_DLFCN_H 1
+
+/* Define to 1 if you have the 'dup2' function. */
+#define HAVE_DUP2 1
+
+/* Define to 1 if you have the `duplocale' function. */
+#define HAVE_DUPLOCALE 1
+
+/* Define if you have the declaration of environ. */
+#define HAVE_ENVIRON_DECL 1
+
+/* Define to 1 if the system has the type `error_t'. */
+#define HAVE_ERROR_T 1
+
+/* Define if the locale_t type contains insufficient information, as on
+ OpenBSD. */
+/* #undef HAVE_FAKE_LOCALES */
+
+/* Define to 1 if you have the `fcntl' function. */
+#define HAVE_FCNTL 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_FEATURES_H 1
+
+/* Define to 1 if you have the `flockfile' function. */
+/* #undef HAVE_FLOCKFILE */
+
+/* Define to 1 if you have the `fnmatch' function. */
+#define HAVE_FNMATCH 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_FNMATCH_H 1
+
+/* Define to 1 if you have the `freelocale' function. */
+#define HAVE_FREELOCALE 1
+
+/* Define to 1 if you have the `fsync' function. */
+#define HAVE_FSYNC 1
+
+/* Define to 1 if you have the `ftruncate' function. */
+#define HAVE_FTRUNCATE 1
+
+/* Define to 1 if you have the `funlockfile' function. */
+/* #undef HAVE_FUNLOCKFILE */
+
+/* Define to 1 if you have the `getcwd' function. */
+#define HAVE_GETCWD 1
+
+/* Define to 1 if you have the `getdelim' function. */
+#define HAVE_GETDELIM 1
+
+/* Define to 1 if you have the `getdtablesize' function. */
+#define HAVE_GETDTABLESIZE 1
+
+/* Define to 1 if you have the `getlocalename_l' function. */
+/* #undef HAVE_GETLOCALENAME_L */
+
+/* Define to 1 if you have the header file. */
+#define HAVE_GETOPT_H 1
+
+/* Define to 1 if you have the `getopt_long_only' function. */
+#define HAVE_GETOPT_LONG_ONLY 1
+
+/* Define to 1 if you have the `gettimeofday' function. */
+#define HAVE_GETTIMEOFDAY 1
+
+/* Define to 1 if you have the `inet_pton' function. */
+/* #undef HAVE_INET_PTON */
+
+/* Define if you have the 'intmax_t' type in or . */
+#define HAVE_INTMAX_T 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_INTTYPES_H 1
+
+/* Define if exists, doesn't clash with , and
+ declares uintmax_t. */
+#define HAVE_INTTYPES_H_WITH_UINTMAX 1
+
+/* Define to 1 if you have the `ioctl' function. */
+#define HAVE_IOCTL 1
+
+/* Define to 1 if defines AF_INET. */
+#define HAVE_IPV4 1
+
+/* Define to 1 if defines AF_INET6. */
+#define HAVE_IPV6 1
+
+/* Define to 1 if you have the `isblank' function. */
+#define HAVE_ISBLANK 1
+
+/* Define to 1 if you have the `iswcntrl' function. */
+#define HAVE_ISWCNTRL 1
+
+/* Define to 1 if you have the `iswctype' function. */
+#define HAVE_ISWCTYPE 1
+
+/* Define if you have and nl_langinfo(CODESET). */
+#define HAVE_LANGINFO_CODESET 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_LANGINFO_H 1
+
+/* Define if your file defines LC_MESSAGES. */
+#define HAVE_LC_MESSAGES 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_LIBINTL_H 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_LIMITS_H 1
+
+/* Define to 1 if the system has the type 'long long int'. */
+#define HAVE_LONG_LONG_INT 1
+
+/* Define to 1 if you have the `lstat' function. */
+#define HAVE_LSTAT 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_MALLOC_H 1
+
+/* Define if the 'malloc' function is POSIX compliant. */
+#define HAVE_MALLOC_POSIX 1
+
+/* Define to 1 if mmap()'s MAP_ANONYMOUS flag is available after including
+ config.h and . */
+#define HAVE_MAP_ANONYMOUS 1
+
+/* Define to 1 if you have the `mbrtowc' function. */
+#define HAVE_MBRTOWC 1
+
+/* Define to 1 if you have the `mbsinit' function. */
+#define HAVE_MBSINIT 1
+
+/* Define to 1 if you have the `mbsrtowcs' function. */
+#define HAVE_MBSRTOWCS 1
+
+/* Define to 1 if declares mbstate_t. */
+#define HAVE_MBSTATE_T 1
+
+/* Define to 1 if you have the `mbtowc' function. */
+#define HAVE_MBTOWC 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_MEMORY_H 1
+
+/* Define to 1 if you have the `mempcpy' function. */
+#define HAVE_MEMPCPY 1
+
+/* Define to 1 if you have the `mkstemp' function. */
+#define HAVE_MKSTEMP 1
+
+/* Define to 1 if you have the `mprotect' function. */
+#define HAVE_MPROTECT 1
+
+/* Define to 1 on MSVC platforms that have the "invalid parameter handler"
+ concept. */
+/* #undef HAVE_MSVC_INVALID_PARAMETER_HANDLER */
+
+/* Define if the locale_t type does not contain the name of each locale
+ category. */
+/* #undef HAVE_NAMELESS_LOCALES */
+
+/* Define to 1 if you have the header file. */
+#define HAVE_NETDB_H 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_NETINET_IN_H 1
+
+/* Define to 1 if you have the `newlocale' function. */
+#define HAVE_NEWLOCALE 1
+
+/* Define to 1 if you have the `nl_langinfo' function. */
+#define HAVE_NL_LANGINFO 1
+
+/* Define to 1 if you have the `open_memstream' function. */
+#define HAVE_OPEN_MEMSTREAM 1
+
+/* Define to 1 if you have the header file. */
+/* #undef HAVE_OS_H */
+
+/* Define to 1 if you have the `pipe' function. */
+#define HAVE_PIPE 1
+
+/* Define to 1 if you have the `pthread_atfork' function. */
+#define HAVE_PTHREAD_ATFORK 1
+
+/* Define if the defines PTHREAD_MUTEX_RECURSIVE. */
+#define HAVE_PTHREAD_MUTEX_RECURSIVE 1
+
+/* Define if the POSIX multithreading library has read/write locks. */
+#define HAVE_PTHREAD_RWLOCK 1
+
+/* Define if the 'pthread_rwlock_rdlock' function prefers a writer to a
+ reader. */
+/* #undef HAVE_PTHREAD_RWLOCK_RDLOCK_PREFER_WRITER */
+
+/* Define to 1 if the pthread_sigmask function can be used (despite bugs). */
+/* #undef HAVE_PTHREAD_SIGMASK */
+
+/* Define to 1 if you have the `raise' function. */
+#define HAVE_RAISE 1
+
+/* Define to 1 if you have the `rawmemchr' function. */
+#define HAVE_RAWMEMCHR 1
+
+/* Define to 1 if you have the `readlink' function. */
+#define HAVE_READLINK 1
+
+/* Define to 1 if you have the `realpath' function. */
+#define HAVE_REALPATH 1
+
+/* Define to 1 if the system has the type `sa_family_t'. */
+#define HAVE_SA_FAMILY_T 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_SEARCH_H 1
+
+/* Define to 1 if you have the header file. */
+/* #undef HAVE_SELINUX_CONTEXT_H */
+
+/* Define to 1 if you have the header file. */
+#define HAVE_SELINUX_SELINUX_H 0
+
+/* Define to 1 if you have the header file. */
+#define HAVE_SEMAPHORE_H 1
+
+/* Define to 1 if you have the `setdtablesize' function. */
+/* #undef HAVE_SETDTABLESIZE */
+
+/* Define to 1 if you have the `setenv' function. */
+#define HAVE_SETENV 1
+
+/* Define to 1 if you have the `shutdown' function. */
+#define HAVE_SHUTDOWN 1
+
+/* Define to 1 if you have the `sigaction' function. */
+#define HAVE_SIGACTION 1
+
+/* Define to 1 if you have the `sigaltstack' function. */
+#define HAVE_SIGALTSTACK 1
+
+/* Define to 1 if the system has the type `siginfo_t'. */
+/* #undef HAVE_SIGINFO_T */
+
+/* Define to 1 if you have the `siginterrupt' function. */
+#define HAVE_SIGINTERRUPT 1
+
+/* Define to 1 if 'sig_atomic_t' is a signed integer type. */
+/* #undef HAVE_SIGNED_SIG_ATOMIC_T */
+
+/* Define to 1 if 'wchar_t' is a signed integer type. */
+/* #undef HAVE_SIGNED_WCHAR_T */
+
+/* Define to 1 if 'wint_t' is a signed integer type. */
+/* #undef HAVE_SIGNED_WINT_T */
+
+/* Define to 1 if the system has the type `sigset_t'. */
+#define HAVE_SIGSET_T 1
+
+/* Define to 1 if you have the `sleep' function. */
+#define HAVE_SLEEP 1
+
+/* Define to 1 if you have the `snprintf' function. */
+#define HAVE_SNPRINTF 1
+
+/* Define if the return value of the snprintf function is the number of of
+ bytes (excluding the terminating NUL) that would have been produced if the
+ buffer had been large enough. */
+#define HAVE_SNPRINTF_RETVAL_C99 1
+
+/* Define if the locale_t type is as on Solaris 11.4. */
+/* #undef HAVE_SOLARIS114_LOCALES */
+
+/* Define to 1 if you have the header file. */
+#define HAVE_STDINT_H 1
+
+/* Define if exists, doesn't clash with , and declares
+ uintmax_t. */
+#define HAVE_STDINT_H_WITH_UINTMAX 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_STDLIB_H 1
+
+/* Define to 1 if you have the `stpcpy' function. */
+#define HAVE_STPCPY 1
+
+/* Define if you have the stpncpy() function and it works. */
+#define HAVE_STPNCPY 1
+
+/* Define to 1 if you have the `strchrnul' function. */
+#define HAVE_STRCHRNUL 1
+
+/* Define to 1 if you have the `strerror_r' function. */
+#define HAVE_STRERROR_R 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_STRINGS_H 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_STRING_H 1
+
+/* Define to 1 if you have the `strndup' function. */
+#define HAVE_STRNDUP 1
+
+/* Define to 1 if you have the `strnlen' function. */
+#define HAVE_STRNLEN 1
+
+/* Define to 1 if `decimal_point' is member of `struct lconv'. */
+/* #undef HAVE_STRUCT_LCONV_DECIMAL_POINT */
+
+/* Define to 1 if `sa_sigaction' is member of `struct sigaction'. */
+#define HAVE_STRUCT_SIGACTION_SA_SIGACTION 1
+
+/* Define to 1 if the system has the type `struct sockaddr_storage'. */
+#define HAVE_STRUCT_SOCKADDR_STORAGE 1
+
+/* Define to 1 if `ss_family' is member of `struct sockaddr_storage'. */
+#define HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY 1
+
+/* Define to 1 if `st_atimensec' is member of `struct stat'. */
+/* #undef HAVE_STRUCT_STAT_ST_ATIMENSEC */
+
+/* Define to 1 if `st_atimespec.tv_nsec' is member of `struct stat'. */
+/* #undef HAVE_STRUCT_STAT_ST_ATIMESPEC_TV_NSEC */
+
+/* Define to 1 if `st_atim.st__tim.tv_nsec' is member of `struct stat'. */
+/* #undef HAVE_STRUCT_STAT_ST_ATIM_ST__TIM_TV_NSEC */
+
+/* Define to 1 if `st_atim.tv_nsec' is member of `struct stat'. */
+#define HAVE_STRUCT_STAT_ST_ATIM_TV_NSEC 1
+
+/* Define to 1 if `st_birthtimensec' is member of `struct stat'. */
+/* #undef HAVE_STRUCT_STAT_ST_BIRTHTIMENSEC */
+
+/* Define to 1 if `st_birthtimespec.tv_nsec' is member of `struct stat'. */
+/* #undef HAVE_STRUCT_STAT_ST_BIRTHTIMESPEC_TV_NSEC */
+
+/* Define to 1 if `st_birthtim.tv_nsec' is member of `struct stat'. */
+/* #undef HAVE_STRUCT_STAT_ST_BIRTHTIM_TV_NSEC */
+
+/* Define to 1 if you have the `symlink' function. */
+#define HAVE_SYMLINK 1
+
+/* Define to 1 if you have the header file. */
+/* #undef HAVE_SYS_BITYPES_H */
+
+/* Define to 1 if you have the header file. */
+#define HAVE_SYS_CDEFS_H 1
+
+/* Define to 1 if you have the header file. */
+/* #undef HAVE_SYS_INTTYPES_H */
+
+/* Define to 1 if you have the header file. */
+#define HAVE_SYS_IOCTL_H 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_SYS_MMAN_H 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_SYS_PARAM_H 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_SYS_SELECT_H 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_SYS_SOCKET_H 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_SYS_STAT_H 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_SYS_TIME_H 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_SYS_TYPES_H 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_SYS_UIO_H 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_SYS_WAIT_H 1
+
+/* Define to 1 if you have the `towlower' function. */
+#define HAVE_TOWLOWER 1
+
+/* Define to 1 if you have the `tsearch' function. */
+#define HAVE_TSEARCH 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_UNISTD_H 1
+
+/* Define to 1 if you have the `unsetenv' function. */
+#define HAVE_UNSETENV 1
+
+/* Define to 1 if the system has the type 'unsigned long long int'. */
+#define HAVE_UNSIGNED_LONG_LONG_INT 1
+
+/* Define to 1 if you have the `uselocale' function. */
+#define HAVE_USELOCALE 1
+
+/* Define to 1 if you have the `usleep' function. */
+#define HAVE_USLEEP 1
+
+/* Define to 1 if you have the `vasnprintf' function. */
+/* #undef HAVE_VASNPRINTF */
+
+/* Define to 1 if you have the `vasprintf' function. */
+#define HAVE_VASPRINTF 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_WCHAR_H 1
+
+/* Define if you have the 'wchar_t' type. */
+#define HAVE_WCHAR_T 1
+
+/* Define to 1 if you have the `wcrtomb' function. */
+#define HAVE_WCRTOMB 1
+
+/* Define to 1 if you have the `wcslen' function. */
+#define HAVE_WCSLEN 1
+
+/* Define to 1 if you have the `wcsnlen' function. */
+#define HAVE_WCSNLEN 1
+
+/* Define to 1 if you have the `wctob' function. */
+#define HAVE_WCTOB 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_WCTYPE_H 1
+
+/* Define to 1 if you have the header file. */
+/* #undef HAVE_WINSOCK2_H */
+
+/* Define if you have the 'wint_t' type. */
+#define HAVE_WINT_T 1
+
+/* Define to 1 if you have the `wmemchr' function. */
+#define HAVE_WMEMCHR 1
+
+/* Define to 1 if you have the `wmemcpy' function. */
+#define HAVE_WMEMCPY 1
+
+/* Define to 1 if you have the `wmempcpy' function. */
+#define HAVE_WMEMPCPY 1
+
+/* This value is set to 1 to indicate that the system argz facility works */
+#define HAVE_WORKING_ARGZ 1
+
+/* Define to 1 if O_NOATIME works. */
+#define HAVE_WORKING_O_NOATIME 1
+
+/* Define to 1 if O_NOFOLLOW works. */
+#define HAVE_WORKING_O_NOFOLLOW 1
+
+/* Define if the uselocale function exists any may safely be called. */
+#define HAVE_WORKING_USELOCALE 1
+
+/* Define to 1 if you have the header file. */
+/* #undef HAVE_WS2TCPIP_H */
+
+/* Define to 1 if you have the header file. */
+#define HAVE_XLOCALE_H 1
+
+/* Define to 1 if the system has the type `_Bool'. */
+#define HAVE__BOOL 1
+
+/* Define to 1 if you have the `_set_invalid_parameter_handler' function. */
+/* #undef HAVE__SET_INVALID_PARAMETER_HANDLER */
+
+/* Define to 1 if the compiler supports __builtin_expect,
+ and to 2 if does. */
+#define HAVE___BUILTIN_EXPECT 1
+#ifndef HAVE___BUILTIN_EXPECT
+# define __builtin_expect(e, c) (e)
+#elif HAVE___BUILTIN_EXPECT == 2
+# include
+#endif
+
+
+/* Define to 1 if the compiler supports the keyword '__inline'. */
+#define HAVE___INLINE 1
+
+/* Define to 1 if you have the `__xpg_strerror_r' function. */
+#define HAVE___XPG_STRERROR_R 1
+
+/* Define to 1 if 'lstat' dereferences a symlink specified with a trailing
+ slash. */
+#define LSTAT_FOLLOWS_SLASHED_SYMLINK 1
+
+/* Define to the sub-directory in which libtool stores uninstalled libraries.
+ */
+#define LT_OBJDIR ".libs/"
+
+/* If malloc(0) is != NULL, define this to 1. Otherwise define this to 0. */
+#define MALLOC_0_IS_NONNULL 1
+
+/* Define to a substitute value for mmap()'s MAP_ANONYMOUS flag. */
+/* #undef MAP_ANONYMOUS */
+
+/* Define if the mbrtowc function does not return (size_t) -2 for empty input.
+ */
+#define MBRTOWC_EMPTY_INPUT_BUG 1
+
+/* Define if the mbrtowc function has the NULL pwc argument bug. */
+/* #undef MBRTOWC_NULL_ARG1_BUG */
+
+/* Define if the mbrtowc function has the NULL string argument bug. */
+/* #undef MBRTOWC_NULL_ARG2_BUG */
+
+/* Define if the mbrtowc function does not return 0 for a NUL character. */
+/* #undef MBRTOWC_NUL_RETVAL_BUG */
+
+/* Define if the mbrtowc function returns a wrong return value. */
+/* #undef MBRTOWC_RETVAL_BUG */
+
+/* Use GNU style printf and scanf. */
+#ifndef __USE_MINGW_ANSI_STDIO
+# define __USE_MINGW_ANSI_STDIO 1
+#endif
+
+
+/* Define to 1 if your C compiler doesn't accept -c and -o together. */
+/* #undef NO_MINUS_C_MINUS_O */
+
+/* Define to 1 if open() fails to recognize a trailing slash. */
+/* #undef OPEN_TRAILING_SLASH_BUG */
+
+/* Name of package */
+#define PACKAGE "augeas"
+
+/* Define to the address where bug reports for this package should be sent. */
+#define PACKAGE_BUGREPORT ""
+
+/* Define to the full name of this package. */
+#define PACKAGE_NAME "augeas"
+
+/* Define to the full name and version of this package. */
+#define PACKAGE_STRING "augeas 1.12.0"
+
+/* Define to the one symbol short name of this package. */
+#define PACKAGE_TARNAME "augeas"
+
+/* Define to the version of this package. */
+#define PACKAGE_VERSION "1.12.0"
+
+/* Define if exists and defines unusable PRI* macros. */
+/* #undef PRI_MACROS_BROKEN */
+
+/* Define to the type that is the result of default argument promotions of
+ type mode_t. */
+#define PROMOTED_MODE_T mode_t
+
+/* Define if the pthread_in_use() detection is hard. */
+/* #undef PTHREAD_IN_USE_DETECTION_HARD */
+
+/* Define to 1 if pthread_sigmask(), when it fails, returns -1 and sets errno.
+ */
+/* #undef PTHREAD_SIGMASK_FAILS_WITH_ERRNO */
+
+/* Define to 1 if pthread_sigmask may return 0 and have no effect. */
+/* #undef PTHREAD_SIGMASK_INEFFECTIVE */
+
+/* Define to 1 if pthread_sigmask() unblocks signals incorrectly. */
+/* #undef PTHREAD_SIGMASK_UNBLOCK_BUG */
+
+/* Define to l, ll, u, ul, ull, etc., as suitable for constants of type
+ 'ptrdiff_t'. */
+/* #undef PTRDIFF_T_SUFFIX */
+
+/* Define to 1 if readlink fails to recognize a trailing slash. */
+/* #undef READLINK_TRAILING_SLASH_BUG */
+
+/* Define to 1 if stat needs help when passed a file name with a trailing
+ slash */
+/* #undef REPLACE_FUNC_STAT_FILE */
+
+/* Define if nl_langinfo exists but is overridden by gnulib. */
+#define REPLACE_NL_LANGINFO 1
+
+/* Define to 1 if strerror(0) does not return a message implying success. */
+/* #undef REPLACE_STRERROR_0 */
+
+/* Define if vasnprintf exists but is overridden by gnulib. */
+/* #undef REPLACE_VASNPRINTF */
+
+/* Define to l, ll, u, ul, ull, etc., as suitable for constants of type
+ 'sig_atomic_t'. */
+/* #undef SIG_ATOMIC_T_SUFFIX */
+
+/* Define as the maximum value of type 'size_t', if the system doesn't define
+ it. */
+#ifndef SIZE_MAX
+/* # undef SIZE_MAX */
+#endif
+
+/* Define to l, ll, u, ul, ull, etc., as suitable for constants of type
+ 'size_t'. */
+/* #undef SIZE_T_SUFFIX */
+
+/* If using the C implementation of alloca, define if you know the
+ direction of stack growth for your system; otherwise it will be
+ automatically deduced at runtime.
+ STACK_DIRECTION > 0 => grows toward higher addresses
+ STACK_DIRECTION < 0 => grows toward lower addresses
+ STACK_DIRECTION = 0 => direction of growth unknown */
+/* #undef STACK_DIRECTION */
+
+/* Define to 1 if the `S_IS*' macros in do not work properly. */
+/* #undef STAT_MACROS_BROKEN */
+
+/* Define to 1 if you have the ANSI C header files. */
+#define STDC_HEADERS 1
+
+/* Define to 1 if the type of the st_atim member of a struct stat is struct
+ timespec. */
+#define TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC 1
+
+/* Define if the POSIX multithreading library can be used. */
+#define USE_POSIX_THREADS 1
+
+/* Define if references to the POSIX multithreading library should be made
+ weak. */
+#define USE_POSIX_THREADS_WEAK 1
+
+/* Define if the GNU Pth multithreading library can be used. */
+/* #undef USE_PTH_THREADS */
+
+/* Define if references to the GNU Pth multithreading library should be made
+ weak. */
+/* #undef USE_PTH_THREADS_WEAK */
+
+/* Define if the old Solaris multithreading library can be used. */
+/* #undef USE_SOLARIS_THREADS */
+
+/* Define if references to the old Solaris multithreading library should be
+ made weak. */
+/* #undef USE_SOLARIS_THREADS_WEAK */
+
+/* Enable extensions on AIX 3, Interix. */
+#ifndef _ALL_SOURCE
+# define _ALL_SOURCE 1
+#endif
+/* Enable general extensions on macOS. */
+#ifndef _DARWIN_C_SOURCE
+# define _DARWIN_C_SOURCE 1
+#endif
+/* Enable GNU extensions on systems that have them. */
+#ifndef _GNU_SOURCE
+# define _GNU_SOURCE 1
+#endif
+/* Enable NetBSD extensions on NetBSD. */
+#ifndef _NETBSD_SOURCE
+# define _NETBSD_SOURCE 1
+#endif
+/* Enable OpenBSD extensions on NetBSD. */
+#ifndef _OPENBSD_SOURCE
+# define _OPENBSD_SOURCE 1
+#endif
+/* Enable threading extensions on Solaris. */
+#ifndef _POSIX_PTHREAD_SEMANTICS
+# define _POSIX_PTHREAD_SEMANTICS 1
+#endif
+/* Enable extensions specified by ISO/IEC TS 18661-5:2014. */
+#ifndef __STDC_WANT_IEC_60559_ATTRIBS_EXT__
+# define __STDC_WANT_IEC_60559_ATTRIBS_EXT__ 1
+#endif
+/* Enable extensions specified by ISO/IEC TS 18661-1:2014. */
+#ifndef __STDC_WANT_IEC_60559_BFP_EXT__
+# define __STDC_WANT_IEC_60559_BFP_EXT__ 1
+#endif
+/* Enable extensions specified by ISO/IEC TS 18661-2:2015. */
+#ifndef __STDC_WANT_IEC_60559_DFP_EXT__
+# define __STDC_WANT_IEC_60559_DFP_EXT__ 1
+#endif
+/* Enable extensions specified by ISO/IEC TS 18661-4:2015. */
+#ifndef __STDC_WANT_IEC_60559_FUNCS_EXT__
+# define __STDC_WANT_IEC_60559_FUNCS_EXT__ 1
+#endif
+/* Enable extensions specified by ISO/IEC TS 18661-3:2015. */
+#ifndef __STDC_WANT_IEC_60559_TYPES_EXT__
+# define __STDC_WANT_IEC_60559_TYPES_EXT__ 1
+#endif
+/* Enable extensions specified by ISO/IEC TR 24731-2:2010. */
+#ifndef __STDC_WANT_LIB_EXT2__
+# define __STDC_WANT_LIB_EXT2__ 1
+#endif
+/* Enable extensions specified by ISO/IEC 24747:2009. */
+#ifndef __STDC_WANT_MATH_SPEC_FUNCS__
+# define __STDC_WANT_MATH_SPEC_FUNCS__ 1
+#endif
+/* Enable extensions on HP NonStop. */
+#ifndef _TANDEM_SOURCE
+# define _TANDEM_SOURCE 1
+#endif
+/* Enable X/Open extensions if necessary. HP-UX 11.11 defines
+ mbstate_t only if _XOPEN_SOURCE is defined to 500, regardless of
+ whether compiling with -Ae or -D_HPUX_SOURCE=1. */
+#ifndef _XOPEN_SOURCE
+/* # undef _XOPEN_SOURCE */
+#endif
+/* Enable X/Open compliant socket functions that do not require linking
+ with -lxnet on HP-UX 11.11. */
+#ifndef _HPUX_ALT_XOPEN_SOCKET_API
+# define _HPUX_ALT_XOPEN_SOCKET_API 1
+#endif
+/* Enable general extensions on Solaris. */
+#ifndef __EXTENSIONS__
+# define __EXTENSIONS__ 1
+#endif
+
+
+/* Define if the native Windows multithreading API can be used. */
+/* #undef USE_WINDOWS_THREADS */
+
+/* Version number of package */
+#define VERSION "1.12.0"
+
+/* Define to 1 if unsetenv returns void instead of int. */
+/* #undef VOID_UNSETENV */
+
+/* Define to l, ll, u, ul, ull, etc., as suitable for constants of type
+ 'wchar_t'. */
+/* #undef WCHAR_T_SUFFIX */
+
+/* Define if WSAStartup is needed. */
+/* #undef WINDOWS_SOCKETS */
+
+/* Define to l, ll, u, ul, ull, etc., as suitable for constants of type
+ 'wint_t'. */
+/* #undef WINT_T_SUFFIX */
+
+/* Define WORDS_BIGENDIAN to 1 if your processor stores words with the most
+ significant byte first (like Motorola and SPARC, unlike Intel). */
+#if defined AC_APPLE_UNIVERSAL_BUILD
+# if defined __BIG_ENDIAN__
+# define WORDS_BIGENDIAN 1
+# endif
+#else
+# ifndef WORDS_BIGENDIAN
+/* # undef WORDS_BIGENDIAN */
+# endif
+#endif
+
+/* Define to 1 if `lex' declares `yytext' as a `char *' by default, not a
+ `char[]'. */
+/* #undef YYTEXT_POINTER */
+
+/* Enable large inode numbers on Mac OS X 10.5. */
+#define _DARWIN_USE_64_BIT_INODE 1
+
+/* Number of bits in a file offset, on hosts where this is settable. */
+/* #undef _FILE_OFFSET_BITS */
+
+/* Define for large files, on AIX-style hosts. */
+/* #undef _LARGE_FILES */
+
+/* Define to 1 on Solaris. */
+/* #undef _LCONV_C99 */
+
+/* Define to 1 if on MINIX. */
+/* #undef _MINIX */
+
+/* Define to 1 to make NetBSD features available. MINIX 3 needs this. */
+#define _NETBSD_SOURCE 1
+
+/* The _Noreturn keyword of C11. */
+#ifndef _Noreturn
+# if (defined __cplusplus \
+ && ((201103 <= __cplusplus && !(__GNUC__ == 4 && __GNUC_MINOR__ == 7)) \
+ || (defined _MSC_VER && 1900 <= _MSC_VER)))
+# define _Noreturn [[noreturn]]
+# elif ((!defined __cplusplus || defined __clang__) \
+ && (201112 <= (defined __STDC_VERSION__ ? __STDC_VERSION__ : 0) \
+ || 4 < __GNUC__ + (7 <= __GNUC_MINOR__)))
+ /* _Noreturn works as-is. */
+# elif 2 < __GNUC__ + (8 <= __GNUC_MINOR__) || 0x5110 <= __SUNPRO_C
+# define _Noreturn __attribute__ ((__noreturn__))
+# elif 1200 <= (defined _MSC_VER ? _MSC_VER : 0)
+# define _Noreturn __declspec (noreturn)
+# else
+# define _Noreturn
+# endif
+#endif
+
+
+/* Define to 2 if the system does not provide POSIX.1 features except with
+ this defined. */
+/* #undef _POSIX_1_SOURCE */
+
+/* Define to 1 in order to get the POSIX compatible declarations of socket
+ functions. */
+/* #undef _POSIX_PII_SOCKET */
+
+/* Define to 1 if you need to in order for 'stat' and other things to work. */
+/* #undef _POSIX_SOURCE */
+
+/* Define if you want to include , so that it consistently
+ overrides 's RE_DUP_MAX. */
+#define _REGEX_INCLUDE_LIMITS_H 1
+
+/* Define if you want regoff_t to be at least as wide POSIX requires. */
+#define _REGEX_LARGE_OFFSETS 1
+
+/* For standard stat data types on VMS. */
+#define _USE_STD_STAT 1
+
+/* Define to rpl_ if the getopt replacement functions and variables should be
+ used. */
+#define __GETOPT_PREFIX rpl_
+
+/* Define to 1 if the system predates C++11. */
+/* #undef __STDC_CONSTANT_MACROS */
+
+/* Define to 1 if the system predates C++11. */
+/* #undef __STDC_LIMIT_MACROS */
+
+/* Define so that glibc/gnulib argp.h does not typedef error_t. */
+/* #undef __error_t_defined */
+
+/* The _GL_ASYNC_SAFE marker should be attached to functions that are
+ signal handlers (for signals other than SIGABRT, SIGPIPE) or can be
+ invoked from such signal handlers. Such functions have some restrictions:
+ * All functions that it calls should be marked _GL_ASYNC_SAFE as well,
+ or should be listed as async-signal-safe in POSIX
+
+ section 2.4.3. Note that malloc(), sprintf(), and fwrite(), in
+ particular, are NOT async-signal-safe.
+ * All memory locations (variables and struct fields) that these functions
+ access must be marked 'volatile'. This holds for both read and write
+ accesses. Otherwise the compiler might optimize away stores to and
+ reads from such locations that occur in the program, depending on its
+ data flow analysis. For example, when the program contains a loop
+ that is intended to inspect a variable set from within a signal handler
+ while (!signal_occurred)
+ ;
+ the compiler is allowed to transform this into an endless loop if the
+ variable 'signal_occurred' is not declared 'volatile'.
+ Additionally, recall that:
+ * A signal handler should not modify errno (except if it is a handler
+ for a fatal signal and ends by raising the same signal again, thus
+ provoking the termination of the process). If it invokes a function
+ that may clobber errno, it needs to save and restore the value of
+ errno. */
+#define _GL_ASYNC_SAFE
+
+
+/* Define to a type to use for 'error_t' if it is not otherwise available. */
+/* #undef error_t */
+
+/* Please see the Gnulib manual for how to use these macros.
+
+ Suppress extern inline with HP-UX cc, as it appears to be broken; see
+ .
+
+ Suppress extern inline with Sun C in standards-conformance mode, as it
+ mishandles inline functions that call each other. E.g., for 'inline void f
+ (void) { } inline void g (void) { f (); }', c99 incorrectly complains
+ 'reference to static identifier "f" in extern inline function'.
+ This bug was observed with Sun C 5.12 SunOS_i386 2011/11/16.
+
+ Suppress extern inline (with or without __attribute__ ((__gnu_inline__)))
+ on configurations that mistakenly use 'static inline' to implement
+ functions or macros in standard C headers like . For example,
+ if isdigit is mistakenly implemented via a static inline function,
+ a program containing an extern inline function that calls isdigit
+ may not work since the C standard prohibits extern inline functions
+ from calling static functions (ISO C 99 section 6.7.4.(3).
+ This bug is known to occur on:
+
+ OS X 10.8 and earlier; see:
+ https://lists.gnu.org/r/bug-gnulib/2012-12/msg00023.html
+
+ DragonFly; see
+ http://muscles.dragonflybsd.org/bulk/bleeding-edge-potential/latest-per-pkg/ah-tty-0.3.12.log
+
+ FreeBSD; see:
+ https://lists.gnu.org/r/bug-gnulib/2014-07/msg00104.html
+
+ OS X 10.9 has a macro __header_inline indicating the bug is fixed for C and
+ for clang but remains for g++; see .
+ Assume DragonFly and FreeBSD will be similar.
+
+ GCC 4.3 and above with -std=c99 or -std=gnu99 implements ISO C99
+ inline semantics, unless -fgnu89-inline is used. It defines a macro
+ __GNUC_STDC_INLINE__ to indicate this situation or a macro
+ __GNUC_GNU_INLINE__ to indicate the opposite situation.
+ GCC 4.2 with -std=c99 or -std=gnu99 implements the GNU C inline
+ semantics but warns, unless -fgnu89-inline is used:
+ warning: C99 inline functions are not supported; using GNU89
+ warning: to disable this warning use -fgnu89-inline or the gnu_inline function attribute
+ It defines a macro __GNUC_GNU_INLINE__ to indicate this situation.
+ */
+#if (((defined __APPLE__ && defined __MACH__) \
+ || defined __DragonFly__ || defined __FreeBSD__) \
+ && (defined __header_inline \
+ ? (defined __cplusplus && defined __GNUC_STDC_INLINE__ \
+ && ! defined __clang__) \
+ : ((! defined _DONT_USE_CTYPE_INLINE_ \
+ && (defined __GNUC__ || defined __cplusplus)) \
+ || (defined _FORTIFY_SOURCE && 0 < _FORTIFY_SOURCE \
+ && defined __GNUC__ && ! defined __cplusplus))))
+# define _GL_EXTERN_INLINE_STDHEADER_BUG
+#endif
+#if ((__GNUC__ \
+ ? defined __GNUC_STDC_INLINE__ && __GNUC_STDC_INLINE__ \
+ : (199901L <= __STDC_VERSION__ \
+ && !defined __HP_cc \
+ && !defined __PGI \
+ && !(defined __SUNPRO_C && __STDC__))) \
+ && !defined _GL_EXTERN_INLINE_STDHEADER_BUG)
+# define _GL_INLINE inline
+# define _GL_EXTERN_INLINE extern inline
+# define _GL_EXTERN_INLINE_IN_USE
+#elif (2 < __GNUC__ + (7 <= __GNUC_MINOR__) && !defined __STRICT_ANSI__ \
+ && !defined _GL_EXTERN_INLINE_STDHEADER_BUG)
+# if defined __GNUC_GNU_INLINE__ && __GNUC_GNU_INLINE__
+ /* __gnu_inline__ suppresses a GCC 4.2 diagnostic. */
+# define _GL_INLINE extern inline __attribute__ ((__gnu_inline__))
+# else
+# define _GL_INLINE extern inline
+# endif
+# define _GL_EXTERN_INLINE extern
+# define _GL_EXTERN_INLINE_IN_USE
+#else
+# define _GL_INLINE static _GL_UNUSED
+# define _GL_EXTERN_INLINE static _GL_UNUSED
+#endif
+
+/* In GCC 4.6 (inclusive) to 5.1 (exclusive),
+ suppress bogus "no previous prototype for 'FOO'"
+ and "no previous declaration for 'FOO'" diagnostics,
+ when FOO is an inline function in the header; see
+ and
+ . */
+#if __GNUC__ == 4 && 6 <= __GNUC_MINOR__
+# if defined __GNUC_STDC_INLINE__ && __GNUC_STDC_INLINE__
+# define _GL_INLINE_HEADER_CONST_PRAGMA
+# else
+# define _GL_INLINE_HEADER_CONST_PRAGMA \
+ _Pragma ("GCC diagnostic ignored \"-Wsuggest-attribute=const\"")
+# endif
+# define _GL_INLINE_HEADER_BEGIN \
+ _Pragma ("GCC diagnostic push") \
+ _Pragma ("GCC diagnostic ignored \"-Wmissing-prototypes\"") \
+ _Pragma ("GCC diagnostic ignored \"-Wmissing-declarations\"") \
+ _GL_INLINE_HEADER_CONST_PRAGMA
+# define _GL_INLINE_HEADER_END \
+ _Pragma ("GCC diagnostic pop")
+#else
+# define _GL_INLINE_HEADER_BEGIN
+# define _GL_INLINE_HEADER_END
+#endif
+
+/* Always use our fgetfilecon wrapper. */
+/* #undef fgetfilecon */
+
+/* Always use our getfilecon wrapper. */
+/* #undef getfilecon */
+
+/* Define to `int' if doesn't define. */
+/* #undef gid_t */
+
+/* Define to `__inline__' or `__inline' if that's what the C compiler
+ calls it, or to nothing if 'inline' is not supported under any name. */
+#ifndef __cplusplus
+/* #undef inline */
+#endif
+
+/* Define to long or long long if and don't define. */
+/* #undef intmax_t */
+
+/* Work around a bug in Apple GCC 4.0.1 build 5465: In C99 mode, it supports
+ the ISO C 99 semantics of 'extern inline' (unlike the GNU C semantics of
+ earlier versions), but does not display it by setting __GNUC_STDC_INLINE__.
+ __APPLE__ && __MACH__ test for Mac OS X.
+ __APPLE_CC__ tests for the Apple compiler and its version.
+ __STDC_VERSION__ tests for the C99 mode. */
+#if defined __APPLE__ && defined __MACH__ && __APPLE_CC__ >= 5465 && !defined __cplusplus && __STDC_VERSION__ >= 199901L && !defined __GNUC_STDC_INLINE__
+# define __GNUC_STDC_INLINE__ 1
+#endif
+
+/* Always use our lgetfilecon wrapper. */
+/* #undef lgetfilecon */
+
+/* Define to a type if does not define. */
+/* #undef mbstate_t */
+
+/* Define to `int' if does not define. */
+/* #undef mode_t */
+
+/* Define to the type of st_nlink in struct stat, or a supertype. */
+/* #undef nlink_t */
+
+/* Define to `int' if does not define. */
+/* #undef pid_t */
+
+/* Define as the type of the result of subtracting two pointers, if the system
+ doesn't define it. */
+/* #undef ptrdiff_t */
+
+/* Define to rpl_re_comp if the replacement should be used. */
+#define re_comp rpl_re_comp
+
+/* Define to rpl_re_compile_fastmap if the replacement should be used. */
+#define re_compile_fastmap rpl_re_compile_fastmap
+
+/* Define to rpl_re_compile_pattern if the replacement should be used. */
+#define re_compile_pattern rpl_re_compile_pattern
+
+/* Define to rpl_re_exec if the replacement should be used. */
+#define re_exec rpl_re_exec
+
+/* Define to rpl_re_match if the replacement should be used. */
+#define re_match rpl_re_match
+
+/* Define to rpl_re_match_2 if the replacement should be used. */
+#define re_match_2 rpl_re_match_2
+
+/* Define to rpl_re_search if the replacement should be used. */
+#define re_search rpl_re_search
+
+/* Define to rpl_re_search_2 if the replacement should be used. */
+#define re_search_2 rpl_re_search_2
+
+/* Define to rpl_re_set_registers if the replacement should be used. */
+#define re_set_registers rpl_re_set_registers
+
+/* Define to rpl_re_set_syntax if the replacement should be used. */
+#define re_set_syntax rpl_re_set_syntax
+
+/* Define to rpl_re_syntax_options if the replacement should be used. */
+#define re_syntax_options rpl_re_syntax_options
+
+/* Define to rpl_regcomp if the replacement should be used. */
+#define regcomp rpl_regcomp
+
+/* Define to rpl_regerror if the replacement should be used. */
+#define regerror rpl_regerror
+
+/* Define to rpl_regexec if the replacement should be used. */
+#define regexec rpl_regexec
+
+/* Define to rpl_regfree if the replacement should be used. */
+#define regfree rpl_regfree
+
+/* Define to the equivalent of the C99 'restrict' keyword, or to
+ nothing if this is not supported. Do not define if restrict is
+ supported directly. */
+#define restrict __restrict
+/* Work around a bug in Sun C++: it does not support _Restrict or
+ __restrict__, even though the corresponding Sun C compiler ends up with
+ "#define restrict _Restrict" or "#define restrict __restrict__" in the
+ previous line. Perhaps some future version of Sun C++ will work with
+ restrict; if so, hopefully it defines __RESTRICT like Sun C does. */
+#if defined __SUNPRO_CC && !defined __RESTRICT
+# define _Restrict
+# define __restrict__
+#endif
+
+/* Define to `unsigned int' if does not define. */
+/* #undef size_t */
+
+/* type to use in place of socklen_t if not defined */
+/* #undef socklen_t */
+
+/* Define as a signed type of the same size as size_t. */
+/* #undef ssize_t */
+
+/* Define to `int' if doesn't define. */
+/* #undef uid_t */
+
+/* Define as a marker that can be attached to declarations that might not
+ be used. This helps to reduce warnings, such as from
+ GCC -Wunused-parameter. */
+#if __GNUC__ >= 3 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 7)
+# define _GL_UNUSED __attribute__ ((__unused__))
+#else
+# define _GL_UNUSED
+#endif
+/* The name _UNUSED_PARAMETER_ is an earlier spelling, although the name
+ is a misnomer outside of parameter lists. */
+#define _UNUSED_PARAMETER_ _GL_UNUSED
+
+/* gcc supports the "unused" attribute on possibly unused labels, and
+ g++ has since version 4.5. Note to support C++ as well as C,
+ _GL_UNUSED_LABEL should be used with a trailing ; */
+#if !defined __cplusplus || __GNUC__ > 4 \
+ || (__GNUC__ == 4 && __GNUC_MINOR__ >= 5)
+# define _GL_UNUSED_LABEL _GL_UNUSED
+#else
+# define _GL_UNUSED_LABEL
+#endif
+
+/* The __pure__ attribute was added in gcc 2.96. */
+#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 96)
+# define _GL_ATTRIBUTE_PURE __attribute__ ((__pure__))
+#else
+# define _GL_ATTRIBUTE_PURE /* empty */
+#endif
+
+/* The __const__ attribute was added in gcc 2.95. */
+#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 95)
+# define _GL_ATTRIBUTE_CONST __attribute__ ((__const__))
+#else
+# define _GL_ATTRIBUTE_CONST /* empty */
+#endif
+
+/* The __malloc__ attribute was added in gcc 3. */
+#if 3 <= __GNUC__
+# define _GL_ATTRIBUTE_MALLOC __attribute__ ((__malloc__))
+#else
+# define _GL_ATTRIBUTE_MALLOC /* empty */
+#endif
+
+
+/* Define to an unsigned 32-bit type if lacks this type. */
+/* #undef useconds_t */
\ No newline at end of file
diff --git a/libraries/cmake/source/augeas/generated/linux/x86_64/config/datadir.h b/libraries/cmake/source/augeas/generated/linux/x86_64/config/datadir.h
new file mode 100644
index 00000000000..fffefb3afc8
--- /dev/null
+++ b/libraries/cmake/source/augeas/generated/linux/x86_64/config/datadir.h
@@ -0,0 +1 @@
+#define DATADIR "/usr/local/share"
diff --git a/libraries/cmake/source/augeas/generated/macos/aarch64/code/lexer.c b/libraries/cmake/source/augeas/generated/macos/aarch64/code/lexer.c
new file mode 100644
index 00000000000..90a3527c909
--- /dev/null
+++ b/libraries/cmake/source/augeas/generated/macos/aarch64/code/lexer.c
@@ -0,0 +1,2573 @@
+#line 1 "lexer.c"
+/* config.h must precede flex's inclusion of
+ in order for its _GNU_SOURCE definition to take effect. */
+#include
+
+#line 6 "lexer.c"
+
+#define YY_INT_ALIGNED short int
+
+/* A lexical scanner generated by flex */
+
+#define FLEX_SCANNER
+#define YY_FLEX_MAJOR_VERSION 2
+#define YY_FLEX_MINOR_VERSION 6
+#define YY_FLEX_SUBMINOR_VERSION 4
+#if YY_FLEX_SUBMINOR_VERSION > 0
+#define FLEX_BETA
+#endif
+
+#ifdef yy_create_buffer
+#define augl__create_buffer_ALREADY_DEFINED
+#else
+#define yy_create_buffer augl__create_buffer
+#endif
+
+#ifdef yy_delete_buffer
+#define augl__delete_buffer_ALREADY_DEFINED
+#else
+#define yy_delete_buffer augl__delete_buffer
+#endif
+
+#ifdef yy_scan_buffer
+#define augl__scan_buffer_ALREADY_DEFINED
+#else
+#define yy_scan_buffer augl__scan_buffer
+#endif
+
+#ifdef yy_scan_string
+#define augl__scan_string_ALREADY_DEFINED
+#else
+#define yy_scan_string augl__scan_string
+#endif
+
+#ifdef yy_scan_bytes
+#define augl__scan_bytes_ALREADY_DEFINED
+#else
+#define yy_scan_bytes augl__scan_bytes
+#endif
+
+#ifdef yy_init_buffer
+#define augl__init_buffer_ALREADY_DEFINED
+#else
+#define yy_init_buffer augl__init_buffer
+#endif
+
+#ifdef yy_flush_buffer
+#define augl__flush_buffer_ALREADY_DEFINED
+#else
+#define yy_flush_buffer augl__flush_buffer
+#endif
+
+#ifdef yy_load_buffer_state
+#define augl__load_buffer_state_ALREADY_DEFINED
+#else
+#define yy_load_buffer_state augl__load_buffer_state
+#endif
+
+#ifdef yy_switch_to_buffer
+#define augl__switch_to_buffer_ALREADY_DEFINED
+#else
+#define yy_switch_to_buffer augl__switch_to_buffer
+#endif
+
+#ifdef yypush_buffer_state
+#define augl_push_buffer_state_ALREADY_DEFINED
+#else
+#define yypush_buffer_state augl_push_buffer_state
+#endif
+
+#ifdef yypop_buffer_state
+#define augl_pop_buffer_state_ALREADY_DEFINED
+#else
+#define yypop_buffer_state augl_pop_buffer_state
+#endif
+
+#ifdef yyensure_buffer_stack
+#define augl_ensure_buffer_stack_ALREADY_DEFINED
+#else
+#define yyensure_buffer_stack augl_ensure_buffer_stack
+#endif
+
+#ifdef yylex
+#define augl_lex_ALREADY_DEFINED
+#else
+#define yylex augl_lex
+#endif
+
+#ifdef yyrestart
+#define augl_restart_ALREADY_DEFINED
+#else
+#define yyrestart augl_restart
+#endif
+
+#ifdef yylex_init
+#define augl_lex_init_ALREADY_DEFINED
+#else
+#define yylex_init augl_lex_init
+#endif
+
+#ifdef yylex_init_extra
+#define augl_lex_init_extra_ALREADY_DEFINED
+#else
+#define yylex_init_extra augl_lex_init_extra
+#endif
+
+#ifdef yylex_destroy
+#define augl_lex_destroy_ALREADY_DEFINED
+#else
+#define yylex_destroy augl_lex_destroy
+#endif
+
+#ifdef yyget_debug
+#define augl_get_debug_ALREADY_DEFINED
+#else
+#define yyget_debug augl_get_debug
+#endif
+
+#ifdef yyset_debug
+#define augl_set_debug_ALREADY_DEFINED
+#else
+#define yyset_debug augl_set_debug
+#endif
+
+#ifdef yyget_extra
+#define augl_get_extra_ALREADY_DEFINED
+#else
+#define yyget_extra augl_get_extra
+#endif
+
+#ifdef yyset_extra
+#define augl_set_extra_ALREADY_DEFINED
+#else
+#define yyset_extra augl_set_extra
+#endif
+
+#ifdef yyget_in
+#define augl_get_in_ALREADY_DEFINED
+#else
+#define yyget_in augl_get_in
+#endif
+
+#ifdef yyset_in
+#define augl_set_in_ALREADY_DEFINED
+#else
+#define yyset_in augl_set_in
+#endif
+
+#ifdef yyget_out
+#define augl_get_out_ALREADY_DEFINED
+#else
+#define yyget_out augl_get_out
+#endif
+
+#ifdef yyset_out
+#define augl_set_out_ALREADY_DEFINED
+#else
+#define yyset_out augl_set_out
+#endif
+
+#ifdef yyget_leng
+#define augl_get_leng_ALREADY_DEFINED
+#else
+#define yyget_leng augl_get_leng
+#endif
+
+#ifdef yyget_text
+#define augl_get_text_ALREADY_DEFINED
+#else
+#define yyget_text augl_get_text
+#endif
+
+#ifdef yyget_lineno
+#define augl_get_lineno_ALREADY_DEFINED
+#else
+#define yyget_lineno augl_get_lineno
+#endif
+
+#ifdef yyset_lineno
+#define augl_set_lineno_ALREADY_DEFINED
+#else
+#define yyset_lineno augl_set_lineno
+#endif
+
+#ifdef yyget_column
+#define augl_get_column_ALREADY_DEFINED
+#else
+#define yyget_column augl_get_column
+#endif
+
+#ifdef yyset_column
+#define augl_set_column_ALREADY_DEFINED
+#else
+#define yyset_column augl_set_column
+#endif
+
+#ifdef yywrap
+#define augl_wrap_ALREADY_DEFINED
+#else
+#define yywrap augl_wrap
+#endif
+
+#ifdef yyget_lval
+#define augl_get_lval_ALREADY_DEFINED
+#else
+#define yyget_lval augl_get_lval
+#endif
+
+#ifdef yyset_lval
+#define augl_set_lval_ALREADY_DEFINED
+#else
+#define yyset_lval augl_set_lval
+#endif
+
+#ifdef yyget_lloc
+#define augl_get_lloc_ALREADY_DEFINED
+#else
+#define yyget_lloc augl_get_lloc
+#endif
+
+#ifdef yyset_lloc
+#define augl_set_lloc_ALREADY_DEFINED
+#else
+#define yyset_lloc augl_set_lloc
+#endif
+
+#ifdef yyalloc
+#define augl_alloc_ALREADY_DEFINED
+#else
+#define yyalloc augl_alloc
+#endif
+
+#ifdef yyrealloc
+#define augl_realloc_ALREADY_DEFINED
+#else
+#define yyrealloc augl_realloc
+#endif
+
+#ifdef yyfree
+#define augl_free_ALREADY_DEFINED
+#else
+#define yyfree augl_free
+#endif
+
+/* First, we deal with platform-specific or compiler-specific issues. */
+
+/* begin standard C headers. */
+#include
+#include
+#include
+#include
+
+/* end standard C headers. */
+
+/* flex integer type definitions */
+
+#ifndef FLEXINT_H
+#define FLEXINT_H
+
+/* C99 systems have . Non-C99 systems may or may not. */
+
+#if defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
+
+/* C99 says to define __STDC_LIMIT_MACROS before including stdint.h,
+ * if you want the limit (max/min) macros for int types.
+ */
+#ifndef __STDC_LIMIT_MACROS
+#define __STDC_LIMIT_MACROS 1
+#endif
+
+#include
+typedef int8_t flex_int8_t;
+typedef uint8_t flex_uint8_t;
+typedef int16_t flex_int16_t;
+typedef uint16_t flex_uint16_t;
+typedef int32_t flex_int32_t;
+typedef uint32_t flex_uint32_t;
+typedef uint64_t flex_uint64_t;
+#else
+typedef signed char flex_int8_t;
+typedef short int flex_int16_t;
+typedef int flex_int32_t;
+typedef unsigned char flex_uint8_t;
+typedef unsigned short int flex_uint16_t;
+typedef unsigned int flex_uint32_t;
+
+/* Limits of integral types. */
+#ifndef INT8_MIN
+#define INT8_MIN (-128)
+#endif
+#ifndef INT16_MIN
+#define INT16_MIN (-32767-1)
+#endif
+#ifndef INT32_MIN
+#define INT32_MIN (-2147483647-1)
+#endif
+#ifndef INT8_MAX
+#define INT8_MAX (127)
+#endif
+#ifndef INT16_MAX
+#define INT16_MAX (32767)
+#endif
+#ifndef INT32_MAX
+#define INT32_MAX (2147483647)
+#endif
+#ifndef UINT8_MAX
+#define UINT8_MAX (255U)
+#endif
+#ifndef UINT16_MAX
+#define UINT16_MAX (65535U)
+#endif
+#ifndef UINT32_MAX
+#define UINT32_MAX (4294967295U)
+#endif
+
+#ifndef SIZE_MAX
+#define SIZE_MAX (~(size_t)0)
+#endif
+
+#endif /* ! C99 */
+
+#endif /* ! FLEXINT_H */
+
+/* begin standard C++ headers. */
+
+/* TODO: this is always defined, so inline it */
+#define yyconst const
+
+#if defined(__GNUC__) && __GNUC__ >= 3
+#define yynoreturn __attribute__((__noreturn__))
+#else
+#define yynoreturn
+#endif
+
+/* Returned upon end-of-file. */
+#define YY_NULL 0
+
+/* Promotes a possibly negative, possibly signed char to an
+ * integer in range [0..255] for use as an array index.
+ */
+#define YY_SC_TO_UI(c) ((YY_CHAR) (c))
+
+/* An opaque pointer. */
+#ifndef YY_TYPEDEF_YY_SCANNER_T
+#define YY_TYPEDEF_YY_SCANNER_T
+typedef void* yyscan_t;
+#endif
+
+/* For convenience, these vars (plus the bison vars far below)
+ are macros in the reentrant scanner. */
+#define yyin yyg->yyin_r
+#define yyout yyg->yyout_r
+#define yyextra yyg->yyextra_r
+#define yyleng yyg->yyleng_r
+#define yytext yyg->yytext_r
+#define yylineno (YY_CURRENT_BUFFER_LVALUE->yy_bs_lineno)
+#define yycolumn (YY_CURRENT_BUFFER_LVALUE->yy_bs_column)
+#define yy_flex_debug yyg->yy_flex_debug_r
+
+/* Enter a start condition. This macro really ought to take a parameter,
+ * but we do it the disgusting crufty way forced on us by the ()-less
+ * definition of BEGIN.
+ */
+#define BEGIN yyg->yy_start = 1 + 2 *
+/* Translate the current start state into a value that can be later handed
+ * to BEGIN to return to the state. The YYSTATE alias is for lex
+ * compatibility.
+ */
+#define YY_START ((yyg->yy_start - 1) / 2)
+#define YYSTATE YY_START
+/* Action number for EOF rule of a given start state. */
+#define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1)
+/* Special action meaning "start processing a new file". */
+#define YY_NEW_FILE yyrestart( yyin , yyscanner )
+#define YY_END_OF_BUFFER_CHAR 0
+
+/* Size of default input buffer. */
+#ifndef YY_BUF_SIZE
+#ifdef __ia64__
+/* On IA-64, the buffer size is 16k, not 8k.
+ * Moreover, YY_BUF_SIZE is 2*YY_READ_BUF_SIZE in the general case.
+ * Ditto for the __ia64__ case accordingly.
+ */
+#define YY_BUF_SIZE 32768
+#else
+#define YY_BUF_SIZE 16384
+#endif /* __ia64__ */
+#endif
+
+/* The state buf must be large enough to hold one state per character in the main buffer.
+ */
+#define YY_STATE_BUF_SIZE ((YY_BUF_SIZE + 2) * sizeof(yy_state_type))
+
+#ifndef YY_TYPEDEF_YY_BUFFER_STATE
+#define YY_TYPEDEF_YY_BUFFER_STATE
+typedef struct yy_buffer_state *YY_BUFFER_STATE;
+#endif
+
+#ifndef YY_TYPEDEF_YY_SIZE_T
+#define YY_TYPEDEF_YY_SIZE_T
+typedef size_t yy_size_t;
+#endif
+
+#define EOB_ACT_CONTINUE_SCAN 0
+#define EOB_ACT_END_OF_FILE 1
+#define EOB_ACT_LAST_MATCH 2
+
+ /* Note: We specifically omit the test for yy_rule_can_match_eol because it requires
+ * access to the local variable yy_act. Since yyless() is a macro, it would break
+ * existing scanners that call yyless() from OUTSIDE yylex.
+ * One obvious solution it to make yy_act a global. I tried that, and saw
+ * a 5% performance hit in a non-yylineno scanner, because yy_act is
+ * normally declared as a register variable-- so it is not worth it.
+ */
+ #define YY_LESS_LINENO(n) \
+ do { \
+ yy_size_t yyl;\
+ for ( yyl = n; yyl < yyleng; ++yyl )\
+ if ( yytext[yyl] == '\n' )\
+ --yylineno;\
+ }while(0)
+ #define YY_LINENO_REWIND_TO(dst) \
+ do {\
+ const char *p;\
+ for ( p = yy_cp-1; p >= (dst); --p)\
+ if ( *p == '\n' )\
+ --yylineno;\
+ }while(0)
+
+/* Return all but the first "n" matched characters back to the input stream. */
+#define yyless(n) \
+ do \
+ { \
+ /* Undo effects of setting up yytext. */ \
+ int yyless_macro_arg = (n); \
+ YY_LESS_LINENO(yyless_macro_arg);\
+ *yy_cp = yyg->yy_hold_char; \
+ YY_RESTORE_YY_MORE_OFFSET \
+ yyg->yy_c_buf_p = yy_cp = yy_bp + yyless_macro_arg - YY_MORE_ADJ; \
+ YY_DO_BEFORE_ACTION; /* set up yytext again */ \
+ } \
+ while ( 0 )
+#define unput(c) yyunput( c, yyg->yytext_ptr , yyscanner )
+
+#ifndef YY_STRUCT_YY_BUFFER_STATE
+#define YY_STRUCT_YY_BUFFER_STATE
+struct yy_buffer_state
+ {
+ FILE *yy_input_file;
+
+ char *yy_ch_buf; /* input buffer */
+ char *yy_buf_pos; /* current position in input buffer */
+
+ /* Size of input buffer in bytes, not including room for EOB
+ * characters.
+ */
+ int yy_buf_size;
+
+ /* Number of characters read into yy_ch_buf, not including EOB
+ * characters.
+ */
+ yy_size_t yy_n_chars;
+
+ /* Whether we "own" the buffer - i.e., we know we created it,
+ * and can realloc() it to grow it, and should free() it to
+ * delete it.
+ */
+ int yy_is_our_buffer;
+
+ /* Whether this is an "interactive" input source; if so, and
+ * if we're using stdio for input, then we want to use getc()
+ * instead of fread(), to make sure we stop fetching input after
+ * each newline.
+ */
+ int yy_is_interactive;
+
+ /* Whether we're considered to be at the beginning of a line.
+ * If so, '^' rules will be active on the next match, otherwise
+ * not.
+ */
+ int yy_at_bol;
+
+ int yy_bs_lineno; /**< The line count. */
+ int yy_bs_column; /**< The column count. */
+
+ /* Whether to try to fill the input buffer when we reach the
+ * end of it.
+ */
+ int yy_fill_buffer;
+
+ int yy_buffer_status;
+
+#define YY_BUFFER_NEW 0
+#define YY_BUFFER_NORMAL 1
+ /* When an EOF's been seen but there's still some text to process
+ * then we mark the buffer as YY_EOF_PENDING, to indicate that we
+ * shouldn't try reading from the input source any more. We might
+ * still have a bunch of tokens to match, though, because of
+ * possible backing-up.
+ *
+ * When we actually see the EOF, we change the status to "new"
+ * (via yyrestart()), so that the user can continue scanning by
+ * just pointing yyin at a new input file.
+ */
+#define YY_BUFFER_EOF_PENDING 2
+
+ };
+#endif /* !YY_STRUCT_YY_BUFFER_STATE */
+
+/* We provide macros for accessing buffer states in case in the
+ * future we want to put the buffer states in a more general
+ * "scanner state".
+ *
+ * Returns the top of the stack, or NULL.
+ */
+#define YY_CURRENT_BUFFER ( yyg->yy_buffer_stack \
+ ? yyg->yy_buffer_stack[yyg->yy_buffer_stack_top] \
+ : NULL)
+/* Same as previous macro, but useful when we know that the buffer stack is not
+ * NULL or when we need an lvalue. For internal use only.
+ */
+#define YY_CURRENT_BUFFER_LVALUE yyg->yy_buffer_stack[yyg->yy_buffer_stack_top]
+
+void yyrestart ( FILE *input_file , yyscan_t yyscanner );
+void yy_switch_to_buffer ( YY_BUFFER_STATE new_buffer , yyscan_t yyscanner );
+YY_BUFFER_STATE yy_create_buffer ( FILE *file, int size , yyscan_t yyscanner );
+void yy_delete_buffer ( YY_BUFFER_STATE b , yyscan_t yyscanner );
+void yy_flush_buffer ( YY_BUFFER_STATE b , yyscan_t yyscanner );
+void yypush_buffer_state ( YY_BUFFER_STATE new_buffer , yyscan_t yyscanner );
+void yypop_buffer_state ( yyscan_t yyscanner );
+
+static void yyensure_buffer_stack ( yyscan_t yyscanner );
+static void yy_load_buffer_state ( yyscan_t yyscanner );
+static void yy_init_buffer ( YY_BUFFER_STATE b, FILE *file , yyscan_t yyscanner );
+#define YY_FLUSH_BUFFER yy_flush_buffer( YY_CURRENT_BUFFER , yyscanner)
+
+YY_BUFFER_STATE yy_scan_buffer ( char *base, yy_size_t size , yyscan_t yyscanner );
+YY_BUFFER_STATE yy_scan_string ( const char *yy_str , yyscan_t yyscanner );
+YY_BUFFER_STATE yy_scan_bytes ( const char *bytes, yy_size_t len , yyscan_t yyscanner );
+
+void *yyalloc ( yy_size_t , yyscan_t yyscanner );
+void *yyrealloc ( void *, yy_size_t , yyscan_t yyscanner );
+void yyfree ( void * , yyscan_t yyscanner );
+
+#define yy_new_buffer yy_create_buffer
+#define yy_set_interactive(is_interactive) \
+ { \
+ if ( ! YY_CURRENT_BUFFER ){ \
+ yyensure_buffer_stack (yyscanner); \
+ YY_CURRENT_BUFFER_LVALUE = \
+ yy_create_buffer( yyin, YY_BUF_SIZE , yyscanner); \
+ } \
+ YY_CURRENT_BUFFER_LVALUE->yy_is_interactive = is_interactive; \
+ }
+#define yy_set_bol(at_bol) \
+ { \
+ if ( ! YY_CURRENT_BUFFER ){\
+ yyensure_buffer_stack (yyscanner); \
+ YY_CURRENT_BUFFER_LVALUE = \
+ yy_create_buffer( yyin, YY_BUF_SIZE , yyscanner); \
+ } \
+ YY_CURRENT_BUFFER_LVALUE->yy_at_bol = at_bol; \
+ }
+#define YY_AT_BOL() (YY_CURRENT_BUFFER_LVALUE->yy_at_bol)
+
+/* Begin user sect3 */
+
+#define augl_wrap(yyscanner) (/*CONSTCOND*/1)
+#define YY_SKIP_YYWRAP
+typedef flex_uint8_t YY_CHAR;
+
+typedef int yy_state_type;
+
+#define yytext_ptr yytext_r
+
+static yy_state_type yy_get_previous_state ( yyscan_t yyscanner );
+static yy_state_type yy_try_NUL_trans ( yy_state_type current_state , yyscan_t yyscanner);
+static int yy_get_next_buffer ( yyscan_t yyscanner );
+static void yynoreturn yy_fatal_error ( const char* msg , yyscan_t yyscanner );
+
+/* Done after the current pattern has been matched and before the
+ * corresponding action - sets up yytext.
+ */
+#define YY_DO_BEFORE_ACTION \
+ yyg->yytext_ptr = yy_bp; \
+ yyleng = (yy_size_t) (yy_cp - yy_bp); \
+ yyg->yy_hold_char = *yy_cp; \
+ *yy_cp = '\0'; \
+ yyg->yy_c_buf_p = yy_cp;
+#define YY_NUM_RULES 29
+#define YY_END_OF_BUFFER 30
+/* This struct is not used in this scanner,
+ but its presence is necessary. */
+struct yy_trans_info
+ {
+ flex_int32_t yy_verify;
+ flex_int32_t yy_nxt;
+ };
+static const flex_int16_t yy_accept[95] =
+ { 0,
+ 1, 1, 1, 1, 30, 25, 1, 2, 25, 25,
+ 7, 7, 7, 25, 23, 22, 22, 22, 22, 22,
+ 22, 22, 22, 22, 22, 28, 1, 28, 28, 28,
+ 1, 2, 3, 0, 4, 0, 24, 20, 0, 6,
+ 0, 0, 23, 22, 22, 22, 22, 14, 22, 22,
+ 22, 22, 22, 22, 26, 27, 0, 5, 21, 22,
+ 22, 17, 22, 10, 22, 18, 22, 22, 22, 21,
+ 22, 22, 13, 0, 22, 22, 22, 16, 19, 22,
+ 0, 22, 22, 22, 22, 0, 8, 12, 11, 22,
+ 0, 15, 9, 0
+
+ } ;
+
+static const YY_CHAR yy_ec[256] =
+ { 0,
+ 1, 1, 1, 1, 1, 1, 1, 1, 2, 3,
+ 1, 1, 4, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 2, 1, 5, 1, 1, 1, 1, 1, 6,
+ 7, 8, 9, 1, 10, 11, 12, 13, 13, 13,
+ 13, 13, 13, 13, 13, 13, 13, 9, 9, 1,
+ 9, 14, 9, 1, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 9, 16, 9, 1, 17, 1, 18, 17, 19, 20,
+
+ 21, 22, 23, 17, 24, 17, 17, 25, 26, 27,
+ 28, 29, 17, 30, 31, 32, 33, 17, 17, 34,
+ 17, 17, 9, 9, 9, 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
+ } ;
+
+static const YY_CHAR yy_meta[35] =
+ { 0,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 2, 1, 3, 1, 3, 1, 4, 4, 4, 4,
+ 4, 4, 4, 4, 4, 4, 4, 4, 4, 4,
+ 4, 4, 4, 4
+ } ;
+
+static const flex_int16_t yy_base[102] =
+ { 0,
+ 0, 0, 33, 40, 134, 135, 131, 129, 128, 33,
+ 122, 135, 115, 35, 117, 0, 23, 106, 99, 104,
+ 96, 90, 101, 89, 99, 135, 117, 115, 109, 109,
+ 113, 111, 109, 45, 135, 0, 135, 135, 41, 88,
+ 0, 0, 100, 0, 78, 77, 76, 0, 27, 87,
+ 74, 82, 74, 72, 135, 135, 99, 135, 0, 80,
+ 72, 0, 68, 96, 64, 0, 75, 71, 62, 0,
+ 63, 67, 0, 38, 66, 56, 62, 0, 0, 60,
+ 46, 45, 36, 41, 42, 39, 0, 0, 0, 35,
+ 60, 0, 135, 135, 68, 72, 76, 79, 81, 48,
+
+ 83
+ } ;
+
+static const flex_int16_t yy_def[102] =
+ { 0,
+ 94, 1, 95, 95, 94, 94, 94, 94, 94, 96,
+ 94, 94, 94, 97, 98, 99, 99, 99, 99, 99,
+ 99, 99, 99, 99, 99, 94, 94, 94, 94, 94,
+ 94, 94, 94, 96, 94, 96, 94, 94, 97, 94,
+ 97, 100, 98, 99, 99, 99, 99, 99, 99, 99,
+ 99, 99, 99, 99, 94, 94, 94, 94, 101, 99,
+ 99, 99, 99, 99, 99, 99, 99, 99, 99, 101,
+ 99, 99, 99, 94, 99, 99, 99, 99, 99, 99,
+ 94, 99, 99, 99, 99, 94, 99, 99, 99, 99,
+ 94, 99, 94, 0, 94, 94, 94, 94, 94, 94,
+
+ 94
+ } ;
+
+static const flex_int16_t yy_nxt[170] =
+ { 0,
+ 6, 7, 8, 9, 10, 11, 12, 12, 12, 13,
+ 12, 14, 6, 6, 15, 6, 16, 17, 16, 16,
+ 16, 16, 18, 19, 20, 21, 16, 16, 22, 23,
+ 24, 25, 16, 16, 27, 8, 28, 35, 29, 74,
+ 30, 27, 8, 28, 45, 29, 40, 30, 36, 35,
+ 41, 59, 40, 63, 92, 46, 41, 91, 64, 90,
+ 36, 93, 93, 89, 88, 87, 86, 81, 26, 26,
+ 26, 26, 34, 34, 34, 34, 39, 39, 39, 39,
+ 43, 43, 43, 44, 44, 70, 70, 85, 84, 83,
+ 82, 80, 79, 78, 77, 76, 75, 74, 73, 72,
+
+ 71, 33, 69, 68, 67, 66, 65, 62, 61, 60,
+ 42, 58, 57, 32, 31, 56, 55, 33, 31, 54,
+ 53, 52, 51, 50, 49, 48, 47, 42, 38, 37,
+ 33, 32, 31, 94, 5, 94, 94, 94, 94, 94,
+ 94, 94, 94, 94, 94, 94, 94, 94, 94, 94,
+ 94, 94, 94, 94, 94, 94, 94, 94, 94, 94,
+ 94, 94, 94, 94, 94, 94, 94, 94, 94
+ } ;
+
+static const flex_int16_t yy_chk[170] =
+ { 0,
+ 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, 3, 3, 10, 3, 74,
+ 3, 4, 4, 4, 17, 4, 14, 4, 10, 34,
+ 14, 100, 39, 49, 90, 17, 39, 86, 49, 85,
+ 34, 91, 91, 84, 83, 82, 81, 74, 95, 95,
+ 95, 95, 96, 96, 96, 96, 97, 97, 97, 97,
+ 98, 98, 98, 99, 99, 101, 101, 80, 77, 76,
+ 75, 72, 71, 69, 68, 67, 65, 64, 63, 61,
+
+ 60, 57, 54, 53, 52, 51, 50, 47, 46, 45,
+ 43, 40, 33, 32, 31, 30, 29, 28, 27, 25,
+ 24, 23, 22, 21, 20, 19, 18, 15, 13, 11,
+ 9, 8, 7, 5, 94, 94, 94, 94, 94, 94,
+ 94, 94, 94, 94, 94, 94, 94, 94, 94, 94,
+ 94, 94, 94, 94, 94, 94, 94, 94, 94, 94,
+ 94, 94, 94, 94, 94, 94, 94, 94, 94
+ } ;
+
+/* Table of booleans, true if rule could match eol. */
+static const flex_int32_t yy_rule_can_match_eol[30] =
+ { 0,
+0, 1, 1, 1, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, };
+
+/* The intent behind this definition is that it'll catch
+ * any uses of REJECT which flex missed.
+ */
+#define REJECT reject_used_but_not_detected
+#define yymore() yymore_used_but_not_detected
+#define YY_MORE_ADJ 0
+#define YY_RESTORE_YY_MORE_OFFSET
+#line 1 "lexer.l"
+/* Scanner for config specs -*- C -*- */
+#define YY_NO_INPUT 1
+
+#line 16 "lexer.l"
+#include "syntax.h"
+#include "errcode.h"
+
+typedef struct info YYLTYPE;
+#define YYLTYPE_IS_DECLARED 1
+
+#include "parser.h"
+
+/* Advance of NUM lines. */
+# define LOCATION_LINES(Loc, Num) \
+ (Loc).last_column = 0; \
+ (Loc).last_line += Num;
+
+/* Restart: move the first cursor to the last position. */
+# define LOCATION_STEP(Loc) \
+ (Loc).first_column = (Loc).last_column; \
+ (Loc).first_line = (Loc).last_line;
+
+/* The lack of reference counting for filename is intentional */
+#define YY_USER_ACTION \
+ do { \
+ yylloc->last_column += yyleng; \
+ yylloc->filename = augl_get_info(yyscanner)->filename; \
+ yylloc->error = augl_get_info(yyscanner)->error; \
+ } while(0);
+
+#define YY_USER_INIT LOCATION_STEP(*yylloc)
+
+#define YY_EXTRA_TYPE struct state *
+
+int augl_init_lexer(struct state *state, yyscan_t * scanner);
+void augl_close_lexer(yyscan_t *scanner);
+struct info *augl_get_info(yyscan_t yyscanner);
+
+static void loc_update(YYLTYPE *yylloc, const char *s, int len) {
+ for (int i=0; i < len; i++) {
+ if (s[i] == '\n') {
+ LOCATION_LINES(*yylloc, 1);
+ }
+ }
+}
+
+static char *regexp_literal(const char *s, int len) {
+ char *u = unescape(s, len, RX_ESCAPES);
+
+ if (u == NULL)
+ return NULL;
+
+ size_t u_len = strlen(u);
+ regexp_c_locale(&u, &u_len);
+
+ return u;
+}
+#line 810 "lexer.c"
+
+#line 812 "lexer.c"
+
+#define INITIAL 0
+#define COMMENT 1
+
+#ifndef YY_NO_UNISTD_H
+/* Special case for "unistd.h", since it is non-ANSI. We include it way
+ * down here because we want the user's section 1 to have been scanned first.
+ * The user has a chance to override it with an option.
+ */
+#include
+#endif
+
+#ifndef YY_EXTRA_TYPE
+#define YY_EXTRA_TYPE void *
+#endif
+
+/* Holds the entire state of the reentrant scanner. */
+struct yyguts_t
+ {
+
+ /* User-defined. Not touched by flex. */
+ YY_EXTRA_TYPE yyextra_r;
+
+ /* The rest are the same as the globals declared in the non-reentrant scanner. */
+ FILE *yyin_r, *yyout_r;
+ size_t yy_buffer_stack_top; /**< index of top of stack. */
+ size_t yy_buffer_stack_max; /**< capacity of stack. */
+ YY_BUFFER_STATE * yy_buffer_stack; /**< Stack as an array. */
+ char yy_hold_char;
+ yy_size_t yy_n_chars;
+ yy_size_t yyleng_r;
+ char *yy_c_buf_p;
+ int yy_init;
+ int yy_start;
+ int yy_did_buffer_switch_on_eof;
+ int yy_start_stack_ptr;
+ int yy_start_stack_depth;
+ int *yy_start_stack;
+ yy_state_type yy_last_accepting_state;
+ char* yy_last_accepting_cpos;
+
+ int yylineno_r;
+ int yy_flex_debug_r;
+
+ char *yytext_r;
+ int yy_more_flag;
+ int yy_more_len;
+
+ YYSTYPE * yylval_r;
+
+ YYLTYPE * yylloc_r;
+
+ }; /* end struct yyguts_t */
+
+static int yy_init_globals ( yyscan_t yyscanner );
+
+ /* This must go here because YYSTYPE and YYLTYPE are included
+ * from bison output in section 1.*/
+ # define yylval yyg->yylval_r
+
+ # define yylloc yyg->yylloc_r
+
+int yylex_init (yyscan_t* scanner);
+
+int yylex_init_extra ( YY_EXTRA_TYPE user_defined, yyscan_t* scanner);
+
+/* Accessor methods to globals.
+ These are made visible to non-reentrant scanners for convenience. */
+
+int yylex_destroy ( yyscan_t yyscanner );
+
+int yyget_debug ( yyscan_t yyscanner );
+
+void yyset_debug ( int debug_flag , yyscan_t yyscanner );
+
+YY_EXTRA_TYPE yyget_extra ( yyscan_t yyscanner );
+
+void yyset_extra ( YY_EXTRA_TYPE user_defined , yyscan_t yyscanner );
+
+FILE *yyget_in ( yyscan_t yyscanner );
+
+void yyset_in ( FILE * _in_str , yyscan_t yyscanner );
+
+FILE *yyget_out ( yyscan_t yyscanner );
+
+void yyset_out ( FILE * _out_str , yyscan_t yyscanner );
+
+ yy_size_t yyget_leng ( yyscan_t yyscanner );
+
+char *yyget_text ( yyscan_t yyscanner );
+
+int yyget_lineno ( yyscan_t yyscanner );
+
+void yyset_lineno ( int _line_number , yyscan_t yyscanner );
+
+int yyget_column ( yyscan_t yyscanner );
+
+void yyset_column ( int _column_no , yyscan_t yyscanner );
+
+YYSTYPE * yyget_lval ( yyscan_t yyscanner );
+
+void yyset_lval ( YYSTYPE * yylval_param , yyscan_t yyscanner );
+
+ YYLTYPE *yyget_lloc ( yyscan_t yyscanner );
+
+ void yyset_lloc ( YYLTYPE * yylloc_param , yyscan_t yyscanner );
+
+/* Macros after this point can all be overridden by user definitions in
+ * section 1.
+ */
+
+#ifndef YY_SKIP_YYWRAP
+#ifdef __cplusplus
+extern "C" int yywrap ( yyscan_t yyscanner );
+#else
+extern int yywrap ( yyscan_t yyscanner );
+#endif
+#endif
+
+#ifndef YY_NO_UNPUT
+
+#endif
+
+#ifndef yytext_ptr
+static void yy_flex_strncpy ( char *, const char *, int , yyscan_t yyscanner);
+#endif
+
+#ifdef YY_NEED_STRLEN
+static int yy_flex_strlen ( const char * , yyscan_t yyscanner);
+#endif
+
+#ifndef YY_NO_INPUT
+#ifdef __cplusplus
+static int yyinput ( yyscan_t yyscanner );
+#else
+static int input ( yyscan_t yyscanner );
+#endif
+
+#endif
+
+/* Amount of stuff to slurp up with each read. */
+#ifndef YY_READ_BUF_SIZE
+#ifdef __ia64__
+/* On IA-64, the buffer size is 16k, not 8k */
+#define YY_READ_BUF_SIZE 16384
+#else
+#define YY_READ_BUF_SIZE 8192
+#endif /* __ia64__ */
+#endif
+
+/* Copy whatever the last rule matched to the standard output. */
+#ifndef ECHO
+/* This used to be an fputs(), but since the string might contain NUL's,
+ * we now use fwrite().
+ */
+#define ECHO do { if (fwrite( yytext, (size_t) yyleng, 1, yyout )) {} } while (0)
+#endif
+
+/* Gets input and stuffs it into "buf". number of characters read, or YY_NULL,
+ * is returned in "result".
+ */
+#ifndef YY_INPUT
+#define YY_INPUT(buf,result,max_size) \
+ if ( YY_CURRENT_BUFFER_LVALUE->yy_is_interactive ) \
+ { \
+ int c = '*'; \
+ yy_size_t n; \
+ for ( n = 0; n < max_size && \
+ (c = getc( yyin )) != EOF && c != '\n'; ++n ) \
+ buf[n] = (char) c; \
+ if ( c == '\n' ) \
+ buf[n++] = (char) c; \
+ if ( c == EOF && ferror( yyin ) ) \
+ YY_FATAL_ERROR( "input in flex scanner failed" ); \
+ result = n; \
+ } \
+ else \
+ { \
+ errno=0; \
+ while ( (result = (int) fread(buf, 1, (yy_size_t) max_size, yyin)) == 0 && ferror(yyin)) \
+ { \
+ if( errno != EINTR) \
+ { \
+ YY_FATAL_ERROR( "input in flex scanner failed" ); \
+ break; \
+ } \
+ errno=0; \
+ clearerr(yyin); \
+ } \
+ }\
+\
+
+#endif
+
+/* No semi-colon after return; correct usage is to write "yyterminate();" -
+ * we don't want an extra ';' after the "return" because that will cause
+ * some compilers to complain about unreachable statements.
+ */
+#ifndef yyterminate
+#define yyterminate() return YY_NULL
+#endif
+
+/* Number of entries by which start-condition stack grows. */
+#ifndef YY_START_STACK_INCR
+#define YY_START_STACK_INCR 25
+#endif
+
+/* Report a fatal error. */
+#ifndef YY_FATAL_ERROR
+#define YY_FATAL_ERROR(msg) yy_fatal_error( msg , yyscanner)
+#endif
+
+/* end tables serialization structures and prototypes */
+
+/* Default declaration of generated scanner - a define so the user can
+ * easily add parameters.
+ */
+#ifndef YY_DECL
+#define YY_DECL_IS_OURS 1
+
+extern int yylex \
+ (YYSTYPE * yylval_param, YYLTYPE * yylloc_param , yyscan_t yyscanner);
+
+#define YY_DECL int yylex \
+ (YYSTYPE * yylval_param, YYLTYPE * yylloc_param , yyscan_t yyscanner)
+#endif /* !YY_DECL */
+
+/* Code executed at the beginning of each rule, after yytext and yyleng
+ * have been set up.
+ */
+#ifndef YY_USER_ACTION
+#define YY_USER_ACTION
+#endif
+
+/* Code executed at the end of each rule. */
+#ifndef YY_BREAK
+#define YY_BREAK /*LINTED*/break;
+#endif
+
+#define YY_RULE_SETUP \
+ YY_USER_ACTION
+
+/** The main scanner function which does all the work.
+ */
+YY_DECL
+{
+ yy_state_type yy_current_state;
+ char *yy_cp, *yy_bp;
+ int yy_act;
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+
+ yylval = yylval_param;
+
+ yylloc = yylloc_param;
+
+ if ( !yyg->yy_init )
+ {
+ yyg->yy_init = 1;
+
+#ifdef YY_USER_INIT
+ YY_USER_INIT;
+#endif
+
+ if ( ! yyg->yy_start )
+ yyg->yy_start = 1; /* first start state */
+
+ if ( ! yyin )
+ yyin = stdin;
+
+ if ( ! yyout )
+ yyout = stdout;
+
+ if ( ! YY_CURRENT_BUFFER ) {
+ yyensure_buffer_stack (yyscanner);
+ YY_CURRENT_BUFFER_LVALUE =
+ yy_create_buffer( yyin, YY_BUF_SIZE , yyscanner);
+ }
+
+ yy_load_buffer_state( yyscanner );
+ }
+
+ {
+#line 81 "lexer.l"
+
+#line 1097 "lexer.c"
+
+ while ( /*CONSTCOND*/1 ) /* loops until end-of-file is reached */
+ {
+ yy_cp = yyg->yy_c_buf_p;
+
+ /* Support of yytext. */
+ *yy_cp = yyg->yy_hold_char;
+
+ /* yy_bp points to the position in yy_ch_buf of the start of
+ * the current run.
+ */
+ yy_bp = yy_cp;
+
+ yy_current_state = yyg->yy_start;
+yy_match:
+ do
+ {
+ YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)] ;
+ if ( yy_accept[yy_current_state] )
+ {
+ yyg->yy_last_accepting_state = yy_current_state;
+ yyg->yy_last_accepting_cpos = yy_cp;
+ }
+ while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
+ {
+ yy_current_state = (int) yy_def[yy_current_state];
+ if ( yy_current_state >= 95 )
+ yy_c = yy_meta[yy_c];
+ }
+ yy_current_state = yy_nxt[yy_base[yy_current_state] + yy_c];
+ ++yy_cp;
+ }
+ while ( yy_current_state != 94 );
+ yy_cp = yyg->yy_last_accepting_cpos;
+ yy_current_state = yyg->yy_last_accepting_state;
+
+yy_find_action:
+ yy_act = yy_accept[yy_current_state];
+
+ YY_DO_BEFORE_ACTION;
+
+ if ( yy_act != YY_END_OF_BUFFER && yy_rule_can_match_eol[yy_act] )
+ {
+ yy_size_t yyl;
+ for ( yyl = 0; yyl < yyleng; ++yyl )
+ if ( yytext[yyl] == '\n' )
+
+ do{ yylineno++;
+ yycolumn=0;
+ }while(0)
+;
+ }
+
+do_action: /* This label is used only to access EOF actions. */
+
+ switch ( yy_act )
+ { /* beginning of action switch */
+ case 0: /* must back up */
+ /* undo the effects of YY_DO_BEFORE_ACTION */
+ *yy_cp = yyg->yy_hold_char;
+ yy_cp = yyg->yy_last_accepting_cpos;
+ yy_current_state = yyg->yy_last_accepting_state;
+ goto yy_find_action;
+
+case 1:
+YY_RULE_SETUP
+#line 84 "lexer.l"
+LOCATION_STEP(*yylloc);
+ YY_BREAK
+case 2:
+/* rule 2 can match eol */
+YY_RULE_SETUP
+#line 85 "lexer.l"
+LOCATION_LINES(*yylloc, yyleng); LOCATION_STEP(*yylloc);
+ YY_BREAK
+case 3:
+/* rule 3 can match eol */
+YY_RULE_SETUP
+#line 86 "lexer.l"
+LOCATION_LINES(*yylloc, yyleng/2); LOCATION_STEP(*yylloc);
+ YY_BREAK
+
+
+
+case 4:
+/* rule 4 can match eol */
+YY_RULE_SETUP
+#line 91 "lexer.l"
+{
+ loc_update(yylloc, yytext, yyleng);
+ yylval->string = unescape(yytext+1, yyleng-2, STR_ESCAPES);
+ return DQUOTED;
+ }
+ YY_BREAK
+case 5:
+/* rule 5 can match eol */
+YY_RULE_SETUP
+#line 97 "lexer.l"
+{
+ loc_update(yylloc, yytext, yyleng);
+ yylval->regexp.nocase = 1;
+ yylval->regexp.pattern = regexp_literal(yytext+1, yyleng-3);
+ return REGEXP;
+ }
+ YY_BREAK
+case 6:
+/* rule 6 can match eol */
+YY_RULE_SETUP
+#line 104 "lexer.l"
+{
+ loc_update(yylloc, yytext, yyleng);
+ yylval->regexp.nocase = 0;
+ yylval->regexp.pattern = regexp_literal(yytext+1, yyleng-2);
+ return REGEXP;
+ }
+ YY_BREAK
+case 7:
+YY_RULE_SETUP
+#line 111 "lexer.l"
+return yytext[0];
+ YY_BREAK
+case 8:
+YY_RULE_SETUP
+#line 113 "lexer.l"
+return KW_MODULE;
+ YY_BREAK
+case 9:
+/* rule 9 can match eol */
+*yy_cp = yyg->yy_hold_char; /* undo effects of setting up yytext */
+YY_LINENO_REWIND_TO(yy_cp - 1);
+yyg->yy_c_buf_p = yy_cp -= 1;
+YY_DO_BEFORE_ACTION; /* set up yytext again */
+YY_RULE_SETUP
+#line 115 "lexer.l"
+return KW_LET_REC;
+ YY_BREAK
+case 10:
+YY_RULE_SETUP
+#line 117 "lexer.l"
+return KW_LET;
+ YY_BREAK
+case 11:
+YY_RULE_SETUP
+#line 118 "lexer.l"
+return KW_STRING;
+ YY_BREAK
+case 12:
+YY_RULE_SETUP
+#line 119 "lexer.l"
+return KW_REGEXP;
+ YY_BREAK
+case 13:
+YY_RULE_SETUP
+#line 120 "lexer.l"
+return KW_LENS;
+ YY_BREAK
+case 14:
+YY_RULE_SETUP
+#line 121 "lexer.l"
+return KW_IN;
+ YY_BREAK
+case 15:
+YY_RULE_SETUP
+#line 122 "lexer.l"
+return KW_AUTOLOAD;
+ YY_BREAK
+/* tests */
+case 16:
+YY_RULE_SETUP
+#line 125 "lexer.l"
+return KW_TEST;
+ YY_BREAK
+case 17:
+YY_RULE_SETUP
+#line 126 "lexer.l"
+return KW_GET;
+ YY_BREAK
+case 18:
+YY_RULE_SETUP
+#line 127 "lexer.l"
+return KW_PUT;
+ YY_BREAK
+case 19:
+YY_RULE_SETUP
+#line 128 "lexer.l"
+return KW_AFTER;
+ YY_BREAK
+case 20:
+YY_RULE_SETUP
+#line 130 "lexer.l"
+return ARROW;
+ YY_BREAK
+case 21:
+YY_RULE_SETUP
+#line 132 "lexer.l"
+{
+ yylval->string = strndup(yytext, yyleng);
+ return QIDENT;
+ }
+ YY_BREAK
+case 22:
+YY_RULE_SETUP
+#line 136 "lexer.l"
+{
+ yylval->string = strndup(yytext, yyleng);
+ return LIDENT;
+ }
+ YY_BREAK
+case 23:
+YY_RULE_SETUP
+#line 140 "lexer.l"
+{
+ yylval->string = strndup(yytext, yyleng);
+ return UIDENT;
+ }
+ YY_BREAK
+case 24:
+YY_RULE_SETUP
+#line 144 "lexer.l"
+{
+ augl_get_extra(yyscanner)->comment_depth = 1;
+ BEGIN(COMMENT);
+ }
+ YY_BREAK
+case 25:
+YY_RULE_SETUP
+#line 148 "lexer.l"
+{
+ report_error(augl_get_info(yyscanner)->error, AUG_ESYNTAX,
+ "%s:%d:%d: Unexpected character %c",
+ augl_get_info(yyscanner)->filename->str,
+ yylineno, yylloc->first_column, yytext[0]);
+ }
+ YY_BREAK
+case YY_STATE_EOF(INITIAL):
+#line 155 "lexer.l"
+{
+ augl_close_lexer(yyscanner);
+ yyterminate();
+ }
+ YY_BREAK
+
+
+
+case 26:
+YY_RULE_SETUP
+#line 164 "lexer.l"
+{
+ augl_get_extra(yyscanner)->comment_depth += 1;
+ }
+ YY_BREAK
+case 27:
+YY_RULE_SETUP
+#line 167 "lexer.l"
+{
+ augl_get_extra(yyscanner)->comment_depth -= 1;
+ if (augl_get_extra(yyscanner)->comment_depth == 0)
+ BEGIN(INITIAL);
+ }
+ YY_BREAK
+case 28:
+YY_RULE_SETUP
+#line 172 "lexer.l"
+/* Skip */;
+ YY_BREAK
+case YY_STATE_EOF(COMMENT):
+#line 173 "lexer.l"
+{
+ report_error(augl_get_info(yyscanner)->error, AUG_ESYNTAX,
+ "%s:%d:%d: Missing *)",
+ augl_get_info(yyscanner)->filename->str,
+ yylineno, yylloc->first_column);
+ augl_close_lexer(yyscanner);
+ yyterminate();
+ }
+ YY_BREAK
+
+case 29:
+YY_RULE_SETUP
+#line 182 "lexer.l"
+YY_FATAL_ERROR( "flex scanner jammed" );
+ YY_BREAK
+#line 1380 "lexer.c"
+
+ case YY_END_OF_BUFFER:
+ {
+ /* Amount of text matched not including the EOB char. */
+ int yy_amount_of_matched_text = (int) (yy_cp - yyg->yytext_ptr) - 1;
+
+ /* Undo the effects of YY_DO_BEFORE_ACTION. */
+ *yy_cp = yyg->yy_hold_char;
+ YY_RESTORE_YY_MORE_OFFSET
+
+ if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_NEW )
+ {
+ /* We're scanning a new file or input source. It's
+ * possible that this happened because the user
+ * just pointed yyin at a new source and called
+ * yylex(). If so, then we have to assure
+ * consistency between YY_CURRENT_BUFFER and our
+ * globals. Here is the right place to do so, because
+ * this is the first action (other than possibly a
+ * back-up) that will match for the new input source.
+ */
+ yyg->yy_n_chars = YY_CURRENT_BUFFER_LVALUE->yy_n_chars;
+ YY_CURRENT_BUFFER_LVALUE->yy_input_file = yyin;
+ YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = YY_BUFFER_NORMAL;
+ }
+
+ /* Note that here we test for yy_c_buf_p "<=" to the position
+ * of the first EOB in the buffer, since yy_c_buf_p will
+ * already have been incremented past the NUL character
+ * (since all states make transitions on EOB to the
+ * end-of-buffer state). Contrast this with the test
+ * in input().
+ */
+ if ( yyg->yy_c_buf_p <= &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars] )
+ { /* This was really a NUL. */
+ yy_state_type yy_next_state;
+
+ yyg->yy_c_buf_p = yyg->yytext_ptr + yy_amount_of_matched_text;
+
+ yy_current_state = yy_get_previous_state( yyscanner );
+
+ /* Okay, we're now positioned to make the NUL
+ * transition. We couldn't have
+ * yy_get_previous_state() go ahead and do it
+ * for us because it doesn't know how to deal
+ * with the possibility of jamming (and we don't
+ * want to build jamming into it because then it
+ * will run more slowly).
+ */
+
+ yy_next_state = yy_try_NUL_trans( yy_current_state , yyscanner);
+
+ yy_bp = yyg->yytext_ptr + YY_MORE_ADJ;
+
+ if ( yy_next_state )
+ {
+ /* Consume the NUL. */
+ yy_cp = ++yyg->yy_c_buf_p;
+ yy_current_state = yy_next_state;
+ goto yy_match;
+ }
+
+ else
+ {
+ yy_cp = yyg->yy_last_accepting_cpos;
+ yy_current_state = yyg->yy_last_accepting_state;
+ goto yy_find_action;
+ }
+ }
+
+ else switch ( yy_get_next_buffer( yyscanner ) )
+ {
+ case EOB_ACT_END_OF_FILE:
+ {
+ yyg->yy_did_buffer_switch_on_eof = 0;
+
+ if ( yywrap( yyscanner ) )
+ {
+ /* Note: because we've taken care in
+ * yy_get_next_buffer() to have set up
+ * yytext, we can now set up
+ * yy_c_buf_p so that if some total
+ * hoser (like flex itself) wants to
+ * call the scanner after we return the
+ * YY_NULL, it'll still work - another
+ * YY_NULL will get returned.
+ */
+ yyg->yy_c_buf_p = yyg->yytext_ptr + YY_MORE_ADJ;
+
+ yy_act = YY_STATE_EOF(YY_START);
+ goto do_action;
+ }
+
+ else
+ {
+ if ( ! yyg->yy_did_buffer_switch_on_eof )
+ YY_NEW_FILE;
+ }
+ break;
+ }
+
+ case EOB_ACT_CONTINUE_SCAN:
+ yyg->yy_c_buf_p =
+ yyg->yytext_ptr + yy_amount_of_matched_text;
+
+ yy_current_state = yy_get_previous_state( yyscanner );
+
+ yy_cp = yyg->yy_c_buf_p;
+ yy_bp = yyg->yytext_ptr + YY_MORE_ADJ;
+ goto yy_match;
+
+ case EOB_ACT_LAST_MATCH:
+ yyg->yy_c_buf_p =
+ &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars];
+
+ yy_current_state = yy_get_previous_state( yyscanner );
+
+ yy_cp = yyg->yy_c_buf_p;
+ yy_bp = yyg->yytext_ptr + YY_MORE_ADJ;
+ goto yy_find_action;
+ }
+ break;
+ }
+
+ default:
+ YY_FATAL_ERROR(
+ "fatal flex scanner internal error--no action found" );
+ } /* end of action switch */
+ } /* end of scanning one token */
+ } /* end of user's declarations */
+} /* end of yylex */
+
+/* yy_get_next_buffer - try to read in a new buffer
+ *
+ * Returns a code representing an action:
+ * EOB_ACT_LAST_MATCH -
+ * EOB_ACT_CONTINUE_SCAN - continue scanning from current position
+ * EOB_ACT_END_OF_FILE - end of file
+ */
+static int yy_get_next_buffer (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ char *dest = YY_CURRENT_BUFFER_LVALUE->yy_ch_buf;
+ char *source = yyg->yytext_ptr;
+ int number_to_move, i;
+ int ret_val;
+
+ if ( yyg->yy_c_buf_p > &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars + 1] )
+ YY_FATAL_ERROR(
+ "fatal flex scanner internal error--end of buffer missed" );
+
+ if ( YY_CURRENT_BUFFER_LVALUE->yy_fill_buffer == 0 )
+ { /* Don't try to fill the buffer, so this is an EOF. */
+ if ( yyg->yy_c_buf_p - yyg->yytext_ptr - YY_MORE_ADJ == 1 )
+ {
+ /* We matched a single character, the EOB, so
+ * treat this as a final EOF.
+ */
+ return EOB_ACT_END_OF_FILE;
+ }
+
+ else
+ {
+ /* We matched some text prior to the EOB, first
+ * process it.
+ */
+ return EOB_ACT_LAST_MATCH;
+ }
+ }
+
+ /* Try to read more data. */
+
+ /* First move last chars to start of buffer. */
+ number_to_move = (int) (yyg->yy_c_buf_p - yyg->yytext_ptr - 1);
+
+ for ( i = 0; i < number_to_move; ++i )
+ *(dest++) = *(source++);
+
+ if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_EOF_PENDING )
+ /* don't do the read, it's not guaranteed to return an EOF,
+ * just force an EOF
+ */
+ YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars = 0;
+
+ else
+ {
+ yy_size_t num_to_read =
+ YY_CURRENT_BUFFER_LVALUE->yy_buf_size - number_to_move - 1;
+
+ while ( num_to_read <= 0 )
+ { /* Not enough room in the buffer - grow it. */
+
+ /* just a shorter name for the current buffer */
+ YY_BUFFER_STATE b = YY_CURRENT_BUFFER_LVALUE;
+
+ int yy_c_buf_p_offset =
+ (int) (yyg->yy_c_buf_p - b->yy_ch_buf);
+
+ if ( b->yy_is_our_buffer )
+ {
+ yy_size_t new_size = b->yy_buf_size * 2;
+
+ if ( new_size <= 0 )
+ b->yy_buf_size += b->yy_buf_size / 8;
+ else
+ b->yy_buf_size *= 2;
+
+ b->yy_ch_buf = (char *)
+ /* Include room in for 2 EOB chars. */
+ yyrealloc( (void *) b->yy_ch_buf,
+ (yy_size_t) (b->yy_buf_size + 2) , yyscanner );
+ }
+ else
+ /* Can't grow it, we don't own it. */
+ b->yy_ch_buf = NULL;
+
+ if ( ! b->yy_ch_buf )
+ YY_FATAL_ERROR(
+ "fatal error - scanner input buffer overflow" );
+
+ yyg->yy_c_buf_p = &b->yy_ch_buf[yy_c_buf_p_offset];
+
+ num_to_read = YY_CURRENT_BUFFER_LVALUE->yy_buf_size -
+ number_to_move - 1;
+
+ }
+
+ if ( num_to_read > YY_READ_BUF_SIZE )
+ num_to_read = YY_READ_BUF_SIZE;
+
+ /* Read in more data. */
+ YY_INPUT( (&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move]),
+ yyg->yy_n_chars, num_to_read );
+
+ YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars;
+ }
+
+ if ( yyg->yy_n_chars == 0 )
+ {
+ if ( number_to_move == YY_MORE_ADJ )
+ {
+ ret_val = EOB_ACT_END_OF_FILE;
+ yyrestart( yyin , yyscanner);
+ }
+
+ else
+ {
+ ret_val = EOB_ACT_LAST_MATCH;
+ YY_CURRENT_BUFFER_LVALUE->yy_buffer_status =
+ YY_BUFFER_EOF_PENDING;
+ }
+ }
+
+ else
+ ret_val = EOB_ACT_CONTINUE_SCAN;
+
+ if ((yyg->yy_n_chars + number_to_move) > YY_CURRENT_BUFFER_LVALUE->yy_buf_size) {
+ /* Extend the array by 50%, plus the number we really need. */
+ yy_size_t new_size = yyg->yy_n_chars + number_to_move + (yyg->yy_n_chars >> 1);
+ YY_CURRENT_BUFFER_LVALUE->yy_ch_buf = (char *) yyrealloc(
+ (void *) YY_CURRENT_BUFFER_LVALUE->yy_ch_buf, (yy_size_t) new_size , yyscanner );
+ if ( ! YY_CURRENT_BUFFER_LVALUE->yy_ch_buf )
+ YY_FATAL_ERROR( "out of dynamic memory in yy_get_next_buffer()" );
+ /* "- 2" to take care of EOB's */
+ YY_CURRENT_BUFFER_LVALUE->yy_buf_size = (int) (new_size - 2);
+ }
+
+ yyg->yy_n_chars += number_to_move;
+ YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars] = YY_END_OF_BUFFER_CHAR;
+ YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars + 1] = YY_END_OF_BUFFER_CHAR;
+
+ yyg->yytext_ptr = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[0];
+
+ return ret_val;
+}
+
+/* yy_get_previous_state - get the state just before the EOB char was reached */
+
+ static yy_state_type yy_get_previous_state (yyscan_t yyscanner)
+{
+ yy_state_type yy_current_state;
+ char *yy_cp;
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+
+ yy_current_state = yyg->yy_start;
+
+ for ( yy_cp = yyg->yytext_ptr + YY_MORE_ADJ; yy_cp < yyg->yy_c_buf_p; ++yy_cp )
+ {
+ YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1);
+ if ( yy_accept[yy_current_state] )
+ {
+ yyg->yy_last_accepting_state = yy_current_state;
+ yyg->yy_last_accepting_cpos = yy_cp;
+ }
+ while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
+ {
+ yy_current_state = (int) yy_def[yy_current_state];
+ if ( yy_current_state >= 95 )
+ yy_c = yy_meta[yy_c];
+ }
+ yy_current_state = yy_nxt[yy_base[yy_current_state] + yy_c];
+ }
+
+ return yy_current_state;
+}
+
+/* yy_try_NUL_trans - try to make a transition on the NUL character
+ *
+ * synopsis
+ * next_state = yy_try_NUL_trans( current_state );
+ */
+ static yy_state_type yy_try_NUL_trans (yy_state_type yy_current_state , yyscan_t yyscanner)
+{
+ int yy_is_jam;
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; /* This var may be unused depending upon options. */
+ char *yy_cp = yyg->yy_c_buf_p;
+
+ YY_CHAR yy_c = 1;
+ if ( yy_accept[yy_current_state] )
+ {
+ yyg->yy_last_accepting_state = yy_current_state;
+ yyg->yy_last_accepting_cpos = yy_cp;
+ }
+ while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
+ {
+ yy_current_state = (int) yy_def[yy_current_state];
+ if ( yy_current_state >= 95 )
+ yy_c = yy_meta[yy_c];
+ }
+ yy_current_state = yy_nxt[yy_base[yy_current_state] + yy_c];
+ yy_is_jam = (yy_current_state == 94);
+
+ (void)yyg;
+ return yy_is_jam ? 0 : yy_current_state;
+}
+
+#ifndef YY_NO_UNPUT
+
+#endif
+
+#ifndef YY_NO_INPUT
+#ifdef __cplusplus
+ static int yyinput (yyscan_t yyscanner)
+#else
+ static int input (yyscan_t yyscanner)
+#endif
+
+{
+ int c;
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+
+ *yyg->yy_c_buf_p = yyg->yy_hold_char;
+
+ if ( *yyg->yy_c_buf_p == YY_END_OF_BUFFER_CHAR )
+ {
+ /* yy_c_buf_p now points to the character we want to return.
+ * If this occurs *before* the EOB characters, then it's a
+ * valid NUL; if not, then we've hit the end of the buffer.
+ */
+ if ( yyg->yy_c_buf_p < &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars] )
+ /* This was really a NUL. */
+ *yyg->yy_c_buf_p = '\0';
+
+ else
+ { /* need more input */
+ yy_size_t offset = yyg->yy_c_buf_p - yyg->yytext_ptr;
+ ++yyg->yy_c_buf_p;
+
+ switch ( yy_get_next_buffer( yyscanner ) )
+ {
+ case EOB_ACT_LAST_MATCH:
+ /* This happens because yy_g_n_b()
+ * sees that we've accumulated a
+ * token and flags that we need to
+ * try matching the token before
+ * proceeding. But for input(),
+ * there's no matching to consider.
+ * So convert the EOB_ACT_LAST_MATCH
+ * to EOB_ACT_END_OF_FILE.
+ */
+
+ /* Reset buffer status. */
+ yyrestart( yyin , yyscanner);
+
+ /*FALLTHROUGH*/
+
+ case EOB_ACT_END_OF_FILE:
+ {
+ if ( yywrap( yyscanner ) )
+ return 0;
+
+ if ( ! yyg->yy_did_buffer_switch_on_eof )
+ YY_NEW_FILE;
+#ifdef __cplusplus
+ return yyinput(yyscanner);
+#else
+ return input(yyscanner);
+#endif
+ }
+
+ case EOB_ACT_CONTINUE_SCAN:
+ yyg->yy_c_buf_p = yyg->yytext_ptr + offset;
+ break;
+ }
+ }
+ }
+
+ c = *(unsigned char *) yyg->yy_c_buf_p; /* cast for 8-bit char's */
+ *yyg->yy_c_buf_p = '\0'; /* preserve yytext */
+ yyg->yy_hold_char = *++yyg->yy_c_buf_p;
+
+ if ( c == '\n' )
+
+ do{ yylineno++;
+ yycolumn=0;
+ }while(0)
+;
+
+ return c;
+}
+#endif /* ifndef YY_NO_INPUT */
+
+/** Immediately switch to a different input stream.
+ * @param input_file A readable stream.
+ * @param yyscanner The scanner object.
+ * @note This function does not reset the start condition to @c INITIAL .
+ */
+ void yyrestart (FILE * input_file , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+
+ if ( ! YY_CURRENT_BUFFER ){
+ yyensure_buffer_stack (yyscanner);
+ YY_CURRENT_BUFFER_LVALUE =
+ yy_create_buffer( yyin, YY_BUF_SIZE , yyscanner);
+ }
+
+ yy_init_buffer( YY_CURRENT_BUFFER, input_file , yyscanner);
+ yy_load_buffer_state( yyscanner );
+}
+
+/** Switch to a different input buffer.
+ * @param new_buffer The new input buffer.
+ * @param yyscanner The scanner object.
+ */
+ void yy_switch_to_buffer (YY_BUFFER_STATE new_buffer , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+
+ /* TODO. We should be able to replace this entire function body
+ * with
+ * yypop_buffer_state();
+ * yypush_buffer_state(new_buffer);
+ */
+ yyensure_buffer_stack (yyscanner);
+ if ( YY_CURRENT_BUFFER == new_buffer )
+ return;
+
+ if ( YY_CURRENT_BUFFER )
+ {
+ /* Flush out information for old buffer. */
+ *yyg->yy_c_buf_p = yyg->yy_hold_char;
+ YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = yyg->yy_c_buf_p;
+ YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars;
+ }
+
+ YY_CURRENT_BUFFER_LVALUE = new_buffer;
+ yy_load_buffer_state( yyscanner );
+
+ /* We don't actually know whether we did this switch during
+ * EOF (yywrap()) processing, but the only time this flag
+ * is looked at is after yywrap() is called, so it's safe
+ * to go ahead and always set it.
+ */
+ yyg->yy_did_buffer_switch_on_eof = 1;
+}
+
+static void yy_load_buffer_state (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ yyg->yy_n_chars = YY_CURRENT_BUFFER_LVALUE->yy_n_chars;
+ yyg->yytext_ptr = yyg->yy_c_buf_p = YY_CURRENT_BUFFER_LVALUE->yy_buf_pos;
+ yyin = YY_CURRENT_BUFFER_LVALUE->yy_input_file;
+ yyg->yy_hold_char = *yyg->yy_c_buf_p;
+}
+
+/** Allocate and initialize an input buffer state.
+ * @param file A readable stream.
+ * @param size The character buffer size in bytes. When in doubt, use @c YY_BUF_SIZE.
+ * @param yyscanner The scanner object.
+ * @return the allocated buffer state.
+ */
+ YY_BUFFER_STATE yy_create_buffer (FILE * file, int size , yyscan_t yyscanner)
+{
+ YY_BUFFER_STATE b;
+
+ b = (YY_BUFFER_STATE) yyalloc( sizeof( struct yy_buffer_state ) , yyscanner );
+ if ( ! b )
+ YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
+
+ b->yy_buf_size = size;
+
+ /* yy_ch_buf has to be 2 characters longer than the size given because
+ * we need to put in 2 end-of-buffer characters.
+ */
+ b->yy_ch_buf = (char *) yyalloc( (yy_size_t) (b->yy_buf_size + 2) , yyscanner );
+ if ( ! b->yy_ch_buf )
+ YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
+
+ b->yy_is_our_buffer = 1;
+
+ yy_init_buffer( b, file , yyscanner);
+
+ return b;
+}
+
+/** Destroy the buffer.
+ * @param b a buffer created with yy_create_buffer()
+ * @param yyscanner The scanner object.
+ */
+ void yy_delete_buffer (YY_BUFFER_STATE b , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+
+ if ( ! b )
+ return;
+
+ if ( b == YY_CURRENT_BUFFER ) /* Not sure if we should pop here. */
+ YY_CURRENT_BUFFER_LVALUE = (YY_BUFFER_STATE) 0;
+
+ if ( b->yy_is_our_buffer )
+ yyfree( (void *) b->yy_ch_buf , yyscanner );
+
+ yyfree( (void *) b , yyscanner );
+}
+
+/* Initializes or reinitializes a buffer.
+ * This function is sometimes called more than once on the same buffer,
+ * such as during a yyrestart() or at EOF.
+ */
+ static void yy_init_buffer (YY_BUFFER_STATE b, FILE * file , yyscan_t yyscanner)
+
+{
+ int oerrno = errno;
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+
+ yy_flush_buffer( b , yyscanner);
+
+ b->yy_input_file = file;
+ b->yy_fill_buffer = 1;
+
+ /* If b is the current buffer, then yy_init_buffer was _probably_
+ * called from yyrestart() or through yy_get_next_buffer.
+ * In that case, we don't want to reset the lineno or column.
+ */
+ if (b != YY_CURRENT_BUFFER){
+ b->yy_bs_lineno = 1;
+ b->yy_bs_column = 0;
+ }
+
+ b->yy_is_interactive = 0;
+
+ errno = oerrno;
+}
+
+/** Discard all buffered characters. On the next scan, YY_INPUT will be called.
+ * @param b the buffer state to be flushed, usually @c YY_CURRENT_BUFFER.
+ * @param yyscanner The scanner object.
+ */
+ void yy_flush_buffer (YY_BUFFER_STATE b , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ if ( ! b )
+ return;
+
+ b->yy_n_chars = 0;
+
+ /* We always need two end-of-buffer characters. The first causes
+ * a transition to the end-of-buffer state. The second causes
+ * a jam in that state.
+ */
+ b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR;
+ b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR;
+
+ b->yy_buf_pos = &b->yy_ch_buf[0];
+
+ b->yy_at_bol = 1;
+ b->yy_buffer_status = YY_BUFFER_NEW;
+
+ if ( b == YY_CURRENT_BUFFER )
+ yy_load_buffer_state( yyscanner );
+}
+
+/** Pushes the new state onto the stack. The new state becomes
+ * the current state. This function will allocate the stack
+ * if necessary.
+ * @param new_buffer The new state.
+ * @param yyscanner The scanner object.
+ */
+void yypush_buffer_state (YY_BUFFER_STATE new_buffer , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ if (new_buffer == NULL)
+ return;
+
+ yyensure_buffer_stack(yyscanner);
+
+ /* This block is copied from yy_switch_to_buffer. */
+ if ( YY_CURRENT_BUFFER )
+ {
+ /* Flush out information for old buffer. */
+ *yyg->yy_c_buf_p = yyg->yy_hold_char;
+ YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = yyg->yy_c_buf_p;
+ YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars;
+ }
+
+ /* Only push if top exists. Otherwise, replace top. */
+ if (YY_CURRENT_BUFFER)
+ yyg->yy_buffer_stack_top++;
+ YY_CURRENT_BUFFER_LVALUE = new_buffer;
+
+ /* copied from yy_switch_to_buffer. */
+ yy_load_buffer_state( yyscanner );
+ yyg->yy_did_buffer_switch_on_eof = 1;
+}
+
+/** Removes and deletes the top of the stack, if present.
+ * The next element becomes the new top.
+ * @param yyscanner The scanner object.
+ */
+void yypop_buffer_state (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ if (!YY_CURRENT_BUFFER)
+ return;
+
+ yy_delete_buffer(YY_CURRENT_BUFFER , yyscanner);
+ YY_CURRENT_BUFFER_LVALUE = NULL;
+ if (yyg->yy_buffer_stack_top > 0)
+ --yyg->yy_buffer_stack_top;
+
+ if (YY_CURRENT_BUFFER) {
+ yy_load_buffer_state( yyscanner );
+ yyg->yy_did_buffer_switch_on_eof = 1;
+ }
+}
+
+/* Allocates the stack if it does not exist.
+ * Guarantees space for at least one push.
+ */
+static void yyensure_buffer_stack (yyscan_t yyscanner)
+{
+ yy_size_t num_to_alloc;
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+
+ if (!yyg->yy_buffer_stack) {
+
+ /* First allocation is just for 2 elements, since we don't know if this
+ * scanner will even need a stack. We use 2 instead of 1 to avoid an
+ * immediate realloc on the next call.
+ */
+ num_to_alloc = 1; /* After all that talk, this was set to 1 anyways... */
+ yyg->yy_buffer_stack = (struct yy_buffer_state**)yyalloc
+ (num_to_alloc * sizeof(struct yy_buffer_state*)
+ , yyscanner);
+ if ( ! yyg->yy_buffer_stack )
+ YY_FATAL_ERROR( "out of dynamic memory in yyensure_buffer_stack()" );
+
+ memset(yyg->yy_buffer_stack, 0, num_to_alloc * sizeof(struct yy_buffer_state*));
+
+ yyg->yy_buffer_stack_max = num_to_alloc;
+ yyg->yy_buffer_stack_top = 0;
+ return;
+ }
+
+ if (yyg->yy_buffer_stack_top >= (yyg->yy_buffer_stack_max) - 1){
+
+ /* Increase the buffer to prepare for a possible push. */
+ yy_size_t grow_size = 8 /* arbitrary grow size */;
+
+ num_to_alloc = yyg->yy_buffer_stack_max + grow_size;
+ yyg->yy_buffer_stack = (struct yy_buffer_state**)yyrealloc
+ (yyg->yy_buffer_stack,
+ num_to_alloc * sizeof(struct yy_buffer_state*)
+ , yyscanner);
+ if ( ! yyg->yy_buffer_stack )
+ YY_FATAL_ERROR( "out of dynamic memory in yyensure_buffer_stack()" );
+
+ /* zero only the new slots.*/
+ memset(yyg->yy_buffer_stack + yyg->yy_buffer_stack_max, 0, grow_size * sizeof(struct yy_buffer_state*));
+ yyg->yy_buffer_stack_max = num_to_alloc;
+ }
+}
+
+/** Setup the input buffer state to scan directly from a user-specified character buffer.
+ * @param base the character buffer
+ * @param size the size in bytes of the character buffer
+ * @param yyscanner The scanner object.
+ * @return the newly allocated buffer state object.
+ */
+YY_BUFFER_STATE yy_scan_buffer (char * base, yy_size_t size , yyscan_t yyscanner)
+{
+ YY_BUFFER_STATE b;
+
+ if ( size < 2 ||
+ base[size-2] != YY_END_OF_BUFFER_CHAR ||
+ base[size-1] != YY_END_OF_BUFFER_CHAR )
+ /* They forgot to leave room for the EOB's. */
+ return NULL;
+
+ b = (YY_BUFFER_STATE) yyalloc( sizeof( struct yy_buffer_state ) , yyscanner );
+ if ( ! b )
+ YY_FATAL_ERROR( "out of dynamic memory in yy_scan_buffer()" );
+
+ b->yy_buf_size = (int) (size - 2); /* "- 2" to take care of EOB's */
+ b->yy_buf_pos = b->yy_ch_buf = base;
+ b->yy_is_our_buffer = 0;
+ b->yy_input_file = NULL;
+ b->yy_n_chars = b->yy_buf_size;
+ b->yy_is_interactive = 0;
+ b->yy_at_bol = 1;
+ b->yy_fill_buffer = 0;
+ b->yy_buffer_status = YY_BUFFER_NEW;
+
+ yy_switch_to_buffer( b , yyscanner );
+
+ return b;
+}
+
+/** Setup the input buffer state to scan a string. The next call to yylex() will
+ * scan from a @e copy of @a str.
+ * @param yystr a NUL-terminated string to scan
+ * @param yyscanner The scanner object.
+ * @return the newly allocated buffer state object.
+ * @note If you want to scan bytes that may contain NUL values, then use
+ * yy_scan_bytes() instead.
+ */
+YY_BUFFER_STATE yy_scan_string (const char * yystr , yyscan_t yyscanner)
+{
+
+ return yy_scan_bytes( yystr, (int) strlen(yystr) , yyscanner);
+}
+
+/** Setup the input buffer state to scan the given bytes. The next call to yylex() will
+ * scan from a @e copy of @a bytes.
+ * @param yybytes the byte buffer to scan
+ * @param _yybytes_len the number of bytes in the buffer pointed to by @a bytes.
+ * @param yyscanner The scanner object.
+ * @return the newly allocated buffer state object.
+ */
+YY_BUFFER_STATE yy_scan_bytes (const char * yybytes, yy_size_t _yybytes_len , yyscan_t yyscanner)
+{
+ YY_BUFFER_STATE b;
+ char *buf;
+ yy_size_t n;
+ yy_size_t i;
+
+ /* Get memory for full buffer, including space for trailing EOB's. */
+ n = (yy_size_t) (_yybytes_len + 2);
+ buf = (char *) yyalloc( n , yyscanner );
+ if ( ! buf )
+ YY_FATAL_ERROR( "out of dynamic memory in yy_scan_bytes()" );
+
+ for ( i = 0; i < _yybytes_len; ++i )
+ buf[i] = yybytes[i];
+
+ buf[_yybytes_len] = buf[_yybytes_len+1] = YY_END_OF_BUFFER_CHAR;
+
+ b = yy_scan_buffer( buf, n , yyscanner);
+ if ( ! b )
+ YY_FATAL_ERROR( "bad buffer in yy_scan_bytes()" );
+
+ /* It's okay to grow etc. this buffer, and we should throw it
+ * away when we're done.
+ */
+ b->yy_is_our_buffer = 1;
+
+ return b;
+}
+
+#ifndef YY_EXIT_FAILURE
+#define YY_EXIT_FAILURE 2
+#endif
+
+static void yynoreturn yy_fatal_error (const char* msg , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ (void)yyg;
+ fprintf( stderr, "%s\n", msg );
+ exit( YY_EXIT_FAILURE );
+}
+
+/* Redefine yyless() so it works in section 3 code. */
+
+#undef yyless
+#define yyless(n) \
+ do \
+ { \
+ /* Undo effects of setting up yytext. */ \
+ yy_size_t yyless_macro_arg = (n); \
+ YY_LESS_LINENO(yyless_macro_arg);\
+ yytext[yyleng] = yyg->yy_hold_char; \
+ yyg->yy_c_buf_p = yytext + yyless_macro_arg; \
+ yyg->yy_hold_char = *yyg->yy_c_buf_p; \
+ *yyg->yy_c_buf_p = '\0'; \
+ yyleng = yyless_macro_arg; \
+ } \
+ while ( 0 )
+
+/* Accessor methods (get/set functions) to struct members. */
+
+/** Get the user-defined data for this scanner.
+ * @param yyscanner The scanner object.
+ */
+YY_EXTRA_TYPE yyget_extra (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ return yyextra;
+}
+
+/** Get the current line number.
+ * @param yyscanner The scanner object.
+ */
+int yyget_lineno (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+
+ if (! YY_CURRENT_BUFFER)
+ return 0;
+
+ return yylineno;
+}
+
+/** Get the current column number.
+ * @param yyscanner The scanner object.
+ */
+int yyget_column (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+
+ if (! YY_CURRENT_BUFFER)
+ return 0;
+
+ return yycolumn;
+}
+
+/** Get the input stream.
+ * @param yyscanner The scanner object.
+ */
+FILE *yyget_in (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ return yyin;
+}
+
+/** Get the output stream.
+ * @param yyscanner The scanner object.
+ */
+FILE *yyget_out (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ return yyout;
+}
+
+/** Get the length of the current token.
+ * @param yyscanner The scanner object.
+ */
+yy_size_t yyget_leng (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ return yyleng;
+}
+
+/** Get the current token.
+ * @param yyscanner The scanner object.
+ */
+
+char *yyget_text (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ return yytext;
+}
+
+/** Set the user-defined data. This data is never touched by the scanner.
+ * @param user_defined The data to be associated with this scanner.
+ * @param yyscanner The scanner object.
+ */
+void yyset_extra (YY_EXTRA_TYPE user_defined , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ yyextra = user_defined ;
+}
+
+/** Set the current line number.
+ * @param _line_number line number
+ * @param yyscanner The scanner object.
+ */
+void yyset_lineno (int _line_number , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+
+ /* lineno is only valid if an input buffer exists. */
+ if (! YY_CURRENT_BUFFER )
+ YY_FATAL_ERROR( "yyset_lineno called with no buffer" );
+
+ yylineno = _line_number;
+}
+
+/** Set the current column.
+ * @param _column_no column number
+ * @param yyscanner The scanner object.
+ */
+void yyset_column (int _column_no , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+
+ /* column is only valid if an input buffer exists. */
+ if (! YY_CURRENT_BUFFER )
+ YY_FATAL_ERROR( "yyset_column called with no buffer" );
+
+ yycolumn = _column_no;
+}
+
+/** Set the input stream. This does not discard the current
+ * input buffer.
+ * @param _in_str A readable stream.
+ * @param yyscanner The scanner object.
+ * @see yy_switch_to_buffer
+ */
+void yyset_in (FILE * _in_str , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ yyin = _in_str ;
+}
+
+void yyset_out (FILE * _out_str , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ yyout = _out_str ;
+}
+
+int yyget_debug (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ return yy_flex_debug;
+}
+
+void yyset_debug (int _bdebug , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ yy_flex_debug = _bdebug ;
+}
+
+/* Accessor methods for yylval and yylloc */
+
+YYSTYPE * yyget_lval (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ return yylval;
+}
+
+void yyset_lval (YYSTYPE * yylval_param , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ yylval = yylval_param;
+}
+
+YYLTYPE *yyget_lloc (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ return yylloc;
+}
+
+void yyset_lloc (YYLTYPE * yylloc_param , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ yylloc = yylloc_param;
+}
+
+/* User-visible API */
+
+/* yylex_init is special because it creates the scanner itself, so it is
+ * the ONLY reentrant function that doesn't take the scanner as the last argument.
+ * That's why we explicitly handle the declaration, instead of using our macros.
+ */
+int yylex_init(yyscan_t* ptr_yy_globals)
+{
+ if (ptr_yy_globals == NULL){
+ errno = EINVAL;
+ return 1;
+ }
+
+ *ptr_yy_globals = (yyscan_t) yyalloc ( sizeof( struct yyguts_t ), NULL );
+
+ if (*ptr_yy_globals == NULL){
+ errno = ENOMEM;
+ return 1;
+ }
+
+ /* By setting to 0xAA, we expose bugs in yy_init_globals. Leave at 0x00 for releases. */
+ memset(*ptr_yy_globals,0x00,sizeof(struct yyguts_t));
+
+ return yy_init_globals ( *ptr_yy_globals );
+}
+
+/* yylex_init_extra has the same functionality as yylex_init, but follows the
+ * convention of taking the scanner as the last argument. Note however, that
+ * this is a *pointer* to a scanner, as it will be allocated by this call (and
+ * is the reason, too, why this function also must handle its own declaration).
+ * The user defined value in the first argument will be available to yyalloc in
+ * the yyextra field.
+ */
+int yylex_init_extra( YY_EXTRA_TYPE yy_user_defined, yyscan_t* ptr_yy_globals )
+{
+ struct yyguts_t dummy_yyguts;
+
+ yyset_extra (yy_user_defined, &dummy_yyguts);
+
+ if (ptr_yy_globals == NULL){
+ errno = EINVAL;
+ return 1;
+ }
+
+ *ptr_yy_globals = (yyscan_t) yyalloc ( sizeof( struct yyguts_t ), &dummy_yyguts );
+
+ if (*ptr_yy_globals == NULL){
+ errno = ENOMEM;
+ return 1;
+ }
+
+ /* By setting to 0xAA, we expose bugs in
+ yy_init_globals. Leave at 0x00 for releases. */
+ memset(*ptr_yy_globals,0x00,sizeof(struct yyguts_t));
+
+ yyset_extra (yy_user_defined, *ptr_yy_globals);
+
+ return yy_init_globals ( *ptr_yy_globals );
+}
+
+static int yy_init_globals (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ /* Initialization is the same as for the non-reentrant scanner.
+ * This function is called from yylex_destroy(), so don't allocate here.
+ */
+
+ yyg->yy_buffer_stack = NULL;
+ yyg->yy_buffer_stack_top = 0;
+ yyg->yy_buffer_stack_max = 0;
+ yyg->yy_c_buf_p = NULL;
+ yyg->yy_init = 0;
+ yyg->yy_start = 0;
+
+ yyg->yy_start_stack_ptr = 0;
+ yyg->yy_start_stack_depth = 0;
+ yyg->yy_start_stack = NULL;
+
+/* Defined in main.c */
+#ifdef YY_STDINIT
+ yyin = stdin;
+ yyout = stdout;
+#else
+ yyin = NULL;
+ yyout = NULL;
+#endif
+
+ /* For future reference: Set errno on error, since we are called by
+ * yylex_init()
+ */
+ return 0;
+}
+
+/* yylex_destroy is for both reentrant and non-reentrant scanners. */
+int yylex_destroy (yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+
+ /* Pop the buffer stack, destroying each element. */
+ while(YY_CURRENT_BUFFER){
+ yy_delete_buffer( YY_CURRENT_BUFFER , yyscanner );
+ YY_CURRENT_BUFFER_LVALUE = NULL;
+ yypop_buffer_state(yyscanner);
+ }
+
+ /* Destroy the stack itself. */
+ yyfree(yyg->yy_buffer_stack , yyscanner);
+ yyg->yy_buffer_stack = NULL;
+
+ /* Destroy the start condition stack. */
+ yyfree( yyg->yy_start_stack , yyscanner );
+ yyg->yy_start_stack = NULL;
+
+ /* Reset the globals. This is important in a non-reentrant scanner so the next time
+ * yylex() is called, initialization will occur. */
+ yy_init_globals( yyscanner);
+
+ /* Destroy the main struct (reentrant only). */
+ yyfree ( yyscanner , yyscanner );
+ yyscanner = NULL;
+ return 0;
+}
+
+/*
+ * Internal utility routines.
+ */
+
+#ifndef yytext_ptr
+static void yy_flex_strncpy (char* s1, const char * s2, int n , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ (void)yyg;
+
+ int i;
+ for ( i = 0; i < n; ++i )
+ s1[i] = s2[i];
+}
+#endif
+
+#ifdef YY_NEED_STRLEN
+static int yy_flex_strlen (const char * s , yyscan_t yyscanner)
+{
+ int n;
+ for ( n = 0; s[n]; ++n )
+ ;
+
+ return n;
+}
+#endif
+
+void *yyalloc (yy_size_t size , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ (void)yyg;
+ return malloc(size);
+}
+
+void *yyrealloc (void * ptr, yy_size_t size , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ (void)yyg;
+
+ /* The cast to (char *) in the following accommodates both
+ * implementations that use char* generic pointers, and those
+ * that use void* generic pointers. It works with the latter
+ * because both ANSI C and C++ allow castless assignment from
+ * any pointer type to void*, and deal with argument conversions
+ * as though doing an assignment.
+ */
+ return realloc(ptr, size);
+}
+
+void yyfree (void * ptr , yyscan_t yyscanner)
+{
+ struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
+ (void)yyg;
+ free( (char *) ptr ); /* see yyrealloc() for (char *) cast */
+}
+
+#define YYTABLES_NAME "yytables"
+
+#line 182 "lexer.l"
+
+
+void augl_close_lexer(yyscan_t *scanner) {
+ FILE *fp = augl_get_in(scanner);
+
+ if (fp != NULL) {
+ fclose(fp);
+ augl_set_in(NULL, scanner);
+ }
+}
+
+int augl_init_lexer(struct state *state, yyscan_t *scanner) {
+ FILE *f;
+ struct string *name = state->info->filename;
+
+ f = fopen(name->str, "r");
+ if (f == NULL)
+ return -1;
+
+ if (augl_lex_init(scanner) != 0) {
+ fclose(f);
+ return -1;
+ }
+ augl_set_extra(state, *scanner);
+ augl_set_in(f, *scanner);
+ return 0;
+}
+
+struct info *augl_get_info(yyscan_t scanner) {
+ return augl_get_extra(scanner)->info;
+}
+
diff --git a/libraries/cmake/source/augeas/generated/macos/aarch64/code/parser.c b/libraries/cmake/source/augeas/generated/macos/aarch64/code/parser.c
new file mode 100644
index 00000000000..fa7541d8f2e
--- /dev/null
+++ b/libraries/cmake/source/augeas/generated/macos/aarch64/code/parser.c
@@ -0,0 +1,2743 @@
+/* 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 1
+
+/* Push parsers. */
+#define YYPUSH 0
+
+/* Pull parsers. */
+#define YYPULL 1
+
+
+/* Substitute the variable and function names. */
+#define yyparse augl_parse
+#define yylex augl_lex
+#define yyerror augl_error
+#define yydebug augl_debug
+#define yynerrs augl_nerrs
+
+/* First part of user prologue. */
+#line 1 "parser.y"
+
+
+#include
+
+#include "internal.h"
+#include "syntax.h"
+#include "list.h"
+#include "errcode.h"
+#include
+
+/* Work around a problem on FreeBSD where Bison looks for _STDLIB_H
+ * to see if stdlib.h has been included, but the system includes
+ * use _STDLIB_H_
+ */
+#if HAVE_STDLIB_H && ! defined _STDLIB_H
+# include
+# define _STDLIB_H 1
+#endif
+
+#define YYDEBUG 1
+
+int augl_parse_file(struct augeas *aug, const char *name, struct term **term);
+
+typedef void *yyscan_t;
+typedef struct info YYLTYPE;
+#define YYLTYPE_IS_DECLARED 1
+/* The lack of reference counting on filename is intentional */
+# define YYLLOC_DEFAULT(Current, Rhs, N) \
+ do { \
+ (Current).filename = augl_get_info(scanner)->filename; \
+ (Current).error = augl_get_info(scanner)->error; \
+ 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)
+
+#line 121 "parser.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
+
+/* Use api.header.include to #include this header
+ instead of duplicating it here. */
+#ifndef YY_AUGL_PARSER_H_INCLUDED
+# define YY_AUGL_PARSER_H_INCLUDED
+/* Debug traces. */
+#ifndef YYDEBUG
+# define YYDEBUG 0
+#endif
+#if YYDEBUG
+extern int augl_debug;
+#endif
+
+/* Token kinds. */
+#ifndef YYTOKENTYPE
+# define YYTOKENTYPE
+ enum yytokentype
+ {
+ YYEMPTY = -2,
+ YYEOF = 0, /* "end of file" */
+ YYerror = 256, /* error */
+ YYUNDEF = 257, /* "invalid token" */
+ DQUOTED = 258, /* DQUOTED */
+ REGEXP = 259, /* REGEXP */
+ LIDENT = 260, /* LIDENT */
+ UIDENT = 261, /* UIDENT */
+ QIDENT = 262, /* QIDENT */
+ ARROW = 263, /* ARROW */
+ KW_MODULE = 264, /* KW_MODULE */
+ KW_AUTOLOAD = 265, /* KW_AUTOLOAD */
+ KW_LET = 266, /* KW_LET */
+ KW_LET_REC = 267, /* KW_LET_REC */
+ KW_IN = 268, /* KW_IN */
+ KW_STRING = 269, /* KW_STRING */
+ KW_REGEXP = 270, /* KW_REGEXP */
+ KW_LENS = 271, /* KW_LENS */
+ KW_TEST = 272, /* KW_TEST */
+ KW_GET = 273, /* KW_GET */
+ KW_PUT = 274, /* KW_PUT */
+ KW_AFTER = 275 /* KW_AFTER */
+ };
+ typedef enum yytokentype yytoken_kind_t;
+#endif
+/* Token kinds. */
+#define YYEMPTY -2
+#define YYEOF 0
+#define YYerror 256
+#define YYUNDEF 257
+#define DQUOTED 258
+#define REGEXP 259
+#define LIDENT 260
+#define UIDENT 261
+#define QIDENT 262
+#define ARROW 263
+#define KW_MODULE 264
+#define KW_AUTOLOAD 265
+#define KW_LET 266
+#define KW_LET_REC 267
+#define KW_IN 268
+#define KW_STRING 269
+#define KW_REGEXP 270
+#define KW_LENS 271
+#define KW_TEST 272
+#define KW_GET 273
+#define KW_PUT 274
+#define KW_AFTER 275
+
+/* Value type. */
+#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
+union YYSTYPE
+{
+#line 89 "parser.y"
+
+ struct term *term;
+ struct type *type;
+ struct ident *ident;
+ struct tree *tree;
+ char *string;
+ struct {
+ int nocase;
+ char *pattern;
+ } regexp;
+ int intval;
+ enum quant_tag quant;
+
+#line 228 "parser.c"
+
+};
+typedef union YYSTYPE YYSTYPE;
+# define YYSTYPE_IS_TRIVIAL 1
+# define YYSTYPE_IS_DECLARED 1
+#endif
+
+/* 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 augl_parse (struct term **term, yyscan_t scanner);
+
+/* "%code provides" blocks. */
+#line 46 "parser.y"
+
+#include "info.h"
+
+/* Track custom scanner state */
+struct state {
+ struct info *info;
+ unsigned int comment_depth;
+};
+
+
+#line 267 "parser.c"
+
+#endif /* !YY_AUGL_PARSER_H_INCLUDED */
+/* 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_DQUOTED = 3, /* DQUOTED */
+ YYSYMBOL_REGEXP = 4, /* REGEXP */
+ YYSYMBOL_LIDENT = 5, /* LIDENT */
+ YYSYMBOL_UIDENT = 6, /* UIDENT */
+ YYSYMBOL_QIDENT = 7, /* QIDENT */
+ YYSYMBOL_ARROW = 8, /* ARROW */
+ YYSYMBOL_KW_MODULE = 9, /* KW_MODULE */
+ YYSYMBOL_KW_AUTOLOAD = 10, /* KW_AUTOLOAD */
+ YYSYMBOL_KW_LET = 11, /* KW_LET */
+ YYSYMBOL_KW_LET_REC = 12, /* KW_LET_REC */
+ YYSYMBOL_KW_IN = 13, /* KW_IN */
+ YYSYMBOL_KW_STRING = 14, /* KW_STRING */
+ YYSYMBOL_KW_REGEXP = 15, /* KW_REGEXP */
+ YYSYMBOL_KW_LENS = 16, /* KW_LENS */
+ YYSYMBOL_KW_TEST = 17, /* KW_TEST */
+ YYSYMBOL_KW_GET = 18, /* KW_GET */
+ YYSYMBOL_KW_PUT = 19, /* KW_PUT */
+ YYSYMBOL_KW_AFTER = 20, /* KW_AFTER */
+ YYSYMBOL_21_ = 21, /* '=' */
+ YYSYMBOL_22_ = 22, /* '?' */
+ YYSYMBOL_23_ = 23, /* '*' */
+ YYSYMBOL_24_ = 24, /* ';' */
+ YYSYMBOL_25_ = 25, /* '|' */
+ YYSYMBOL_26_ = 26, /* '-' */
+ YYSYMBOL_27_ = 27, /* '.' */
+ YYSYMBOL_28_ = 28, /* '(' */
+ YYSYMBOL_29_ = 29, /* ')' */
+ YYSYMBOL_30_ = 30, /* '[' */
+ YYSYMBOL_31_ = 31, /* ']' */
+ YYSYMBOL_32_ = 32, /* '+' */
+ YYSYMBOL_33_ = 33, /* ':' */
+ YYSYMBOL_34_ = 34, /* '{' */
+ YYSYMBOL_35_ = 35, /* '}' */
+ YYSYMBOL_YYACCEPT = 36, /* $accept */
+ YYSYMBOL_start = 37, /* start */
+ YYSYMBOL_autoload = 38, /* autoload */
+ YYSYMBOL_decls = 39, /* decls */
+ YYSYMBOL_test_exp = 40, /* test_exp */
+ YYSYMBOL_test_special_res = 41, /* test_special_res */
+ YYSYMBOL_exp = 42, /* exp */
+ YYSYMBOL_composeexp = 43, /* composeexp */
+ YYSYMBOL_unionexp = 44, /* unionexp */
+ YYSYMBOL_minusexp = 45, /* minusexp */
+ YYSYMBOL_catexp = 46, /* catexp */
+ YYSYMBOL_appexp = 47, /* appexp */
+ YYSYMBOL_aexp = 48, /* aexp */
+ YYSYMBOL_rexp = 49, /* rexp */
+ YYSYMBOL_rep = 50, /* rep */
+ YYSYMBOL_qid = 51, /* qid */
+ YYSYMBOL_param_list = 52, /* param_list */
+ YYSYMBOL_param = 53, /* param */
+ YYSYMBOL_id = 54, /* id */
+ YYSYMBOL_type = 55, /* type */
+ YYSYMBOL_atype = 56, /* atype */
+ YYSYMBOL_tree_const = 57, /* tree_const */
+ YYSYMBOL_tree_const2 = 58, /* tree_const2 */
+ YYSYMBOL_tree_branch = 59, /* tree_branch */
+ YYSYMBOL_tree_label = 60 /* tree_label */
+};
+typedef enum yysymbol_kind_t yysymbol_kind_t;
+
+
+/* Second part of user prologue. */
+#line 114 "parser.y"
+
+/* Lexer */
+extern int augl_lex (YYSTYPE * yylval_param,struct info * yylloc_param ,yyscan_t yyscanner);
+int augl_init_lexer(struct state *state, yyscan_t * scanner);
+void augl_close_lexer(yyscan_t *scanner);
+int augl_lex_destroy (yyscan_t yyscanner );
+int augl_get_lineno (yyscan_t yyscanner );
+int augl_get_column (yyscan_t yyscanner);
+struct info *augl_get_info(yyscan_t yyscanner);
+char *augl_get_text (yyscan_t yyscanner );
+
+static void augl_error(struct info *locp, struct term **term,
+ yyscan_t scanner, const char *s);
+
+/* TERM construction */
+ static struct info *clone_info(struct info *locp);
+ static struct term *make_module(char *ident, char *autoload,
+ struct term *decls,
+ struct info *locp);
+
+ static struct term *make_bind(char *ident, struct term *params,
+ struct term *exp, struct term *decls,
+ struct info *locp);
+ static struct term *make_bind_rec(char *ident, struct term *exp,
+ struct term *decls, struct info *locp);
+ static struct term *make_let(char *ident, struct term *params,
+ struct term *exp, struct term *body,
+ struct info *locp);
+ static struct term *make_binop(enum term_tag tag,
+ struct term *left, struct term *right,
+ struct info *locp);
+ static struct term *make_unop(enum term_tag tag,
+ struct term *exp, struct info *locp);
+ static struct term *make_ident(char *qname, struct info *locp);
+ static struct term *make_unit_term(struct info *locp);
+ static struct term *make_string_term(char *value, struct info *locp);
+ static struct term *make_regexp_term(char *pattern,
+ int nocase, struct info *locp);
+ static struct term *make_rep(struct term *exp, enum quant_tag quant,
+ struct info *locp);
+
+ static struct term *make_get_test(struct term *lens, struct term *arg,
+ struct info *info);
+ static struct term *make_put_test(struct term *lens, struct term *arg,
+ struct term *cmds, struct info *info);
+ static struct term *make_test(struct term *test, struct term *result,
+ enum test_result_tag tr_tag,
+ struct term *decls, struct info *locp);
+ static struct term *make_tree_value(struct tree *, struct info*);
+ static struct tree *tree_concat(struct tree *, struct tree *);
+
+#define LOC_MERGE(a, b, c) \
+ do { \
+ (a).filename = (b).filename; \
+ (a).first_line = (b).first_line; \
+ (a).first_column = (b).first_column; \
+ (a).last_line = (c).last_line; \
+ (a).last_column = (c).last_column; \
+ (a).error = (b).error; \
+ } while(0);
+
+
+#line 403 "parser.c"
+
+
+#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_int8 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 1
+
+/* 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 /* 1 */
+
+#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 4
+/* YYLAST -- Last index in YYTABLE. */
+#define YYLAST 129
+
+/* YYNTOKENS -- Number of terminals. */
+#define YYNTOKENS 36
+/* YYNNTS -- Number of nonterminals. */
+#define YYNNTS 25
+/* YYNRULES -- Number of rules. */
+#define YYNRULES 61
+/* YYNSTATES -- Number of states. */
+#define YYNSTATES 113
+
+/* YYMAXUTOK -- Last valid token kind. */
+#define YYMAXUTOK 275
+
+
+/* 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_int8 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, 2, 2, 2, 2, 2, 2, 2,
+ 28, 29, 23, 32, 2, 26, 27, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 33, 24,
+ 2, 21, 2, 22, 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, 30, 2, 31, 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, 34, 25, 35, 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, 2, 1, 2, 3, 4,
+ 5, 6, 7, 8, 9, 10, 11, 12, 13, 14,
+ 15, 16, 17, 18, 19, 20
+};
+
+#if YYDEBUG
+/* YYRLINE[YYN] -- Source line where rule number YYN was defined. */
+static const yytype_int16 yyrline[] =
+{
+ 0, 179, 179, 182, 185, 187, 192, 197, 202, 208,
+ 212, 214, 217, 219, 223, 228, 230, 232, 235, 237,
+ 239, 242, 244, 247, 249, 252, 254, 257, 259, 261,
+ 263, 265, 267, 270, 272, 275, 277, 279, 282, 284,
+ 286, 288, 291, 294, 296, 299, 301, 303, 306, 308,
+ 311, 313, 315, 317, 320, 322, 325, 330, 332, 336,
+ 340, 342
+};
+#endif
+
+/** Accessing symbol of state STATE. */
+#define YY_ACCESSING_SYMBOL(State) YY_CAST (yysymbol_kind_t, yystos[State])
+
+#if 1
+/* 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\"", "DQUOTED", "REGEXP",
+ "LIDENT", "UIDENT", "QIDENT", "ARROW", "KW_MODULE", "KW_AUTOLOAD",
+ "KW_LET", "KW_LET_REC", "KW_IN", "KW_STRING", "KW_REGEXP", "KW_LENS",
+ "KW_TEST", "KW_GET", "KW_PUT", "KW_AFTER", "'='", "'?'", "'*'", "';'",
+ "'|'", "'-'", "'.'", "'('", "')'", "'['", "']'", "'+'", "':'", "'{'",
+ "'}'", "$accept", "start", "autoload", "decls", "test_exp",
+ "test_special_res", "exp", "composeexp", "unionexp", "minusexp",
+ "catexp", "appexp", "aexp", "rexp", "rep", "qid", "param_list", "param",
+ "id", "type", "atype", "tree_const", "tree_const2", "tree_branch",
+ "tree_label", YY_NULLPTR
+};
+
+static const char *
+yysymbol_name (yysymbol_kind_t yysymbol)
+{
+ return yytname[yysymbol];
+}
+#endif
+
+#define YYPACT_NINF (-90)
+
+#define yypact_value_is_default(Yyn) \
+ ((Yyn) == YYPACT_NINF)
+
+#define YYTABLE_NINF (-1)
+
+#define yytable_value_is_error(Yyn) \
+ 0
+
+/* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
+ STATE-NUM. */
+static const yytype_int8 yypact[] =
+{
+ -1, 8, 16, -4, -90, 14, 26, 53, -90, 27,
+ 29, 92, -90, 11, 25, -90, -90, -90, -90, -90,
+ -90, 50, 55, 28, -6, -90, 1, 30, 11, 55,
+ 38, -90, 44, 34, 52, 57, 51, 59, 92, 49,
+ -90, 64, 56, 22, 55, 92, -90, -90, -90, 60,
+ 55, -90, 53, 11, -90, 65, 80, -90, 87, 92,
+ 92, 92, -90, -90, -90, -90, -90, 44, -90, -90,
+ -90, 53, 53, -90, 82, -5, 53, -90, 83, -90,
+ 100, 73, 57, 51, 59, 92, 74, -90, -90, 55,
+ -90, -90, -90, -5, 79, 104, -90, 55, -90, 44,
+ -90, -90, 84, -90, -5, 101, 73, 81, -90, -90,
+ 55, -90, -90
+};
+
+/* 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_int8 yydefact[] =
+{
+ 0, 0, 0, 0, 1, 4, 0, 9, 3, 0,
+ 0, 0, 2, 43, 0, 28, 29, 38, 39, 40,
+ 41, 0, 0, 0, 0, 27, 0, 0, 43, 0,
+ 0, 32, 61, 0, 15, 17, 19, 22, 24, 34,
+ 26, 20, 0, 0, 0, 0, 45, 46, 47, 0,
+ 0, 42, 9, 43, 60, 0, 57, 30, 0, 0,
+ 0, 0, 25, 37, 35, 36, 33, 61, 31, 12,
+ 13, 9, 9, 10, 0, 0, 9, 6, 0, 55,
+ 0, 58, 16, 18, 21, 23, 0, 8, 7, 0,
+ 50, 51, 52, 0, 0, 49, 5, 0, 57, 61,
+ 54, 11, 0, 44, 0, 0, 59, 0, 53, 48,
+ 0, 56, 14
+};
+
+/* YYPGOTO[NTERM-NUM]. */
+static const yytype_int8 yypgoto[] =
+{
+ -90, -90, -90, -34, -90, -90, -22, -90, 61, 66,
+ 58, 62, -9, -37, -90, -90, -23, -90, -90, -89,
+ -90, -90, 31, -64, -90
+};
+
+/* YYDEFGOTO[NTERM-NUM]. */
+static const yytype_int8 yydefgoto[] =
+{
+ 0, 2, 7, 12, 23, 71, 33, 34, 35, 36,
+ 37, 38, 39, 40, 66, 25, 27, 28, 49, 94,
+ 95, 41, 81, 55, 56
+};
+
+/* 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_int8 yytable[] =
+{
+ 42, 62, 24, 86, 102, 51, 46, 52, 1, 90,
+ 91, 92, 44, 45, 3, 109, 4, 5, 77, 47,
+ 48, 72, 73, 93, 6, 15, 16, 17, 76, 18,
+ 78, 8, 13, 30, 14, 107, 74, 87, 88, 26,
+ 19, 20, 96, 53, 69, 70, 29, 54, 62, 43,
+ 21, 50, 22, 15, 16, 17, 32, 18, 15, 16,
+ 17, 30, 18, 57, 9, 10, 30, 101, 19, 20,
+ 11, 63, 64, 19, 20, 105, 58, 60, 21, 31,
+ 22, 65, 59, 21, 32, 22, 61, 68, 112, 32,
+ 15, 16, 17, 75, 18, 15, 16, 17, 67, 18,
+ 79, 80, 89, 98, 97, 19, 20, 99, 103, 100,
+ 19, 20, 104, 108, 110, 21, 111, 22, 84, 82,
+ 21, 32, 22, 85, 0, 83, 0, 0, 0, 106
+};
+
+static const yytype_int8 yycheck[] =
+{
+ 22, 38, 11, 67, 93, 28, 5, 29, 9, 14,
+ 15, 16, 18, 19, 6, 104, 0, 21, 52, 18,
+ 19, 43, 44, 28, 10, 3, 4, 5, 50, 7,
+ 53, 5, 5, 11, 5, 99, 45, 71, 72, 28,
+ 18, 19, 76, 5, 22, 23, 21, 3, 85, 21,
+ 28, 21, 30, 3, 4, 5, 34, 7, 3, 4,
+ 5, 11, 7, 29, 11, 12, 11, 89, 18, 19,
+ 17, 22, 23, 18, 19, 97, 24, 26, 28, 29,
+ 30, 32, 25, 28, 34, 30, 27, 31, 110, 34,
+ 3, 4, 5, 33, 7, 3, 4, 5, 34, 7,
+ 35, 21, 20, 3, 21, 18, 19, 34, 29, 35,
+ 18, 19, 8, 29, 13, 28, 35, 30, 60, 58,
+ 28, 34, 30, 61, -1, 59, -1, -1, -1, 98
+};
+
+/* YYSTOS[STATE-NUM] -- The symbol kind of the accessing symbol of
+ state STATE-NUM. */
+static const yytype_int8 yystos[] =
+{
+ 0, 9, 37, 6, 0, 21, 10, 38, 5, 11,
+ 12, 17, 39, 5, 5, 3, 4, 5, 7, 18,
+ 19, 28, 30, 40, 48, 51, 28, 52, 53, 21,
+ 11, 29, 34, 42, 43, 44, 45, 46, 47, 48,
+ 49, 57, 42, 21, 18, 19, 5, 18, 19, 54,
+ 21, 52, 42, 5, 3, 59, 60, 29, 24, 25,
+ 26, 27, 49, 22, 23, 32, 50, 34, 31, 22,
+ 23, 41, 42, 42, 48, 33, 42, 39, 52, 35,
+ 21, 58, 44, 45, 46, 47, 59, 39, 39, 20,
+ 14, 15, 16, 28, 55, 56, 39, 21, 3, 34,
+ 35, 42, 55, 29, 8, 42, 58, 59, 29, 55,
+ 13, 35, 42
+};
+
+/* YYR1[RULE-NUM] -- Symbol kind of the left-hand side of rule RULE-NUM. */
+static const yytype_int8 yyr1[] =
+{
+ 0, 36, 37, 38, 38, 39, 39, 39, 39, 39,
+ 40, 40, 41, 41, 42, 42, 43, 43, 44, 44,
+ 44, 45, 45, 46, 46, 47, 47, 48, 48, 48,
+ 48, 48, 48, 49, 49, 50, 50, 50, 51, 51,
+ 51, 51, 52, 52, 53, 54, 54, 54, 55, 55,
+ 56, 56, 56, 56, 57, 57, 58, 58, 59, 59,
+ 60, 60
+};
+
+/* YYR2[RULE-NUM] -- Number of symbols on the right-hand side of rule RULE-NUM. */
+static const yytype_int8 yyr2[] =
+{
+ 0, 2, 5, 2, 0, 6, 5, 5, 5, 0,
+ 3, 5, 1, 1, 7, 1, 3, 1, 3, 1,
+ 1, 3, 1, 3, 1, 2, 1, 1, 1, 1,
+ 3, 3, 2, 2, 1, 1, 1, 1, 1, 1,
+ 1, 1, 2, 0, 5, 1, 1, 1, 3, 1,
+ 1, 1, 1, 3, 4, 3, 4, 0, 2, 4,
+ 1, 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, term, scanner, 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, term, scanner); \
+ 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, struct term **term, yyscan_t scanner)
+{
+ FILE *yyoutput = yyo;
+ YY_USE (yyoutput);
+ YY_USE (yylocationp);
+ YY_USE (term);
+ YY_USE (scanner);
+ 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, struct term **term, yyscan_t scanner)
+{
+ 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, term, scanner);
+ 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, struct term **term, yyscan_t scanner)
+{
+ 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)]), term, scanner);
+ YYFPRINTF (stderr, "\n");
+ }
+}
+
+# define YY_REDUCE_PRINT(Rule) \
+do { \
+ if (yydebug) \
+ yy_reduce_print (yyssp, yyvsp, yylsp, Rule, term, scanner); \
+} 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
+
+
+/* Context of a parse error. */
+typedef struct
+{
+ yy_state_t *yyssp;
+ yysymbol_kind_t yytoken;
+ YYLTYPE *yylloc;
+} yypcontext_t;
+
+/* Put in YYARG at most YYARGN of the expected tokens given the
+ current YYCTX, and return the number of tokens stored in YYARG. If
+ YYARG is null, return the number of expected tokens (guaranteed to
+ be less than YYNTOKENS). Return YYENOMEM on memory exhaustion.
+ Return 0 if there are more than YYARGN expected tokens, yet fill
+ YYARG up to YYARGN. */
+static int
+yypcontext_expected_tokens (const yypcontext_t *yyctx,
+ yysymbol_kind_t yyarg[], int yyargn)
+{
+ /* Actual size of YYARG. */
+ int yycount = 0;
+ int yyn = yypact[+*yyctx->yyssp];
+ if (!yypact_value_is_default (yyn))
+ {
+ /* Start YYX at -YYN if negative to avoid negative indexes in
+ YYCHECK. In other words, skip the first -YYN actions for
+ this state because they are default actions. */
+ int yyxbegin = yyn < 0 ? -yyn : 0;
+ /* Stay within bounds of both yycheck and yytname. */
+ int yychecklim = YYLAST - yyn + 1;
+ int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS;
+ int yyx;
+ for (yyx = yyxbegin; yyx < yyxend; ++yyx)
+ if (yycheck[yyx + yyn] == yyx && yyx != YYSYMBOL_YYerror
+ && !yytable_value_is_error (yytable[yyx + yyn]))
+ {
+ if (!yyarg)
+ ++yycount;
+ else if (yycount == yyargn)
+ return 0;
+ else
+ yyarg[yycount++] = YY_CAST (yysymbol_kind_t, yyx);
+ }
+ }
+ if (yyarg && yycount == 0 && 0 < yyargn)
+ yyarg[0] = YYSYMBOL_YYEMPTY;
+ return yycount;
+}
+
+
+
+
+#ifndef yystrlen
+# if defined __GLIBC__ && defined _STRING_H
+# define yystrlen(S) (YY_CAST (YYPTRDIFF_T, strlen (S)))
+# else
+/* Return the length of YYSTR. */
+static YYPTRDIFF_T
+yystrlen (const char *yystr)
+{
+ YYPTRDIFF_T yylen;
+ for (yylen = 0; yystr[yylen]; yylen++)
+ continue;
+ return yylen;
+}
+# endif
+#endif
+
+#ifndef yystpcpy
+# if defined __GLIBC__ && defined _STRING_H && defined _GNU_SOURCE
+# define yystpcpy stpcpy
+# else
+/* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in
+ YYDEST. */
+static char *
+yystpcpy (char *yydest, const char *yysrc)
+{
+ char *yyd = yydest;
+ const char *yys = yysrc;
+
+ while ((*yyd++ = *yys++) != '\0')
+ continue;
+
+ return yyd - 1;
+}
+# endif
+#endif
+
+#ifndef yytnamerr
+/* Copy to YYRES the contents of YYSTR after stripping away unnecessary
+ quotes and backslashes, so that it's suitable for yyerror. The
+ heuristic is that double-quoting is unnecessary unless the string
+ contains an apostrophe, a comma, or backslash (other than
+ backslash-backslash). YYSTR is taken from yytname. If YYRES is
+ null, do not copy; instead, return the length of what the result
+ would have been. */
+static YYPTRDIFF_T
+yytnamerr (char *yyres, const char *yystr)
+{
+ if (*yystr == '"')
+ {
+ YYPTRDIFF_T yyn = 0;
+ char const *yyp = yystr;
+ for (;;)
+ switch (*++yyp)
+ {
+ case '\'':
+ case ',':
+ goto do_not_strip_quotes;
+
+ case '\\':
+ if (*++yyp != '\\')
+ goto do_not_strip_quotes;
+ else
+ goto append;
+
+ append:
+ default:
+ if (yyres)
+ yyres[yyn] = *yyp;
+ yyn++;
+ break;
+
+ case '"':
+ if (yyres)
+ yyres[yyn] = '\0';
+ return yyn;
+ }
+ do_not_strip_quotes: ;
+ }
+
+ if (yyres)
+ return yystpcpy (yyres, yystr) - yyres;
+ else
+ return yystrlen (yystr);
+}
+#endif
+
+
+static int
+yy_syntax_error_arguments (const yypcontext_t *yyctx,
+ yysymbol_kind_t yyarg[], int yyargn)
+{
+ /* Actual size of YYARG. */
+ int yycount = 0;
+ /* There are many possibilities here to consider:
+ - If this state is a consistent state with a default action, then
+ the only way this function was invoked is if the default action
+ is an error action. In that case, don't check for expected
+ tokens because there are none.
+ - The only way there can be no lookahead present (in yychar) is if
+ this state is a consistent state with a default action. Thus,
+ detecting the absence of a lookahead is sufficient to determine
+ that there is no unexpected or expected token to report. In that
+ case, just report a simple "syntax error".
+ - Don't assume there isn't a lookahead just because this state is a
+ consistent state with a default action. There might have been a
+ previous inconsistent state, consistent state with a non-default
+ action, or user semantic action that manipulated yychar.
+ - Of course, the expected token list depends on states to have
+ correct lookahead information, and it depends on the parser not
+ to perform extra reductions after fetching a lookahead from the
+ scanner and before detecting a syntax error. Thus, state merging
+ (from LALR or IELR) and default reductions corrupt the expected
+ token list. However, the list is correct for canonical LR with
+ one exception: it will still contain any token that will not be
+ accepted due to an error action in a later state.
+ */
+ if (yyctx->yytoken != YYSYMBOL_YYEMPTY)
+ {
+ int yyn;
+ if (yyarg)
+ yyarg[yycount] = yyctx->yytoken;
+ ++yycount;
+ yyn = yypcontext_expected_tokens (yyctx,
+ yyarg ? yyarg + 1 : yyarg, yyargn - 1);
+ if (yyn == YYENOMEM)
+ return YYENOMEM;
+ else
+ yycount += yyn;
+ }
+ return yycount;
+}
+
+/* Copy into *YYMSG, which is of size *YYMSG_ALLOC, an error message
+ about the unexpected token YYTOKEN for the state stack whose top is
+ YYSSP.
+
+ Return 0 if *YYMSG was successfully written. Return -1 if *YYMSG is
+ not large enough to hold the message. In that case, also set
+ *YYMSG_ALLOC to the required number of bytes. Return YYENOMEM if the
+ required number of bytes is too large to store. */
+static int
+yysyntax_error (YYPTRDIFF_T *yymsg_alloc, char **yymsg,
+ const yypcontext_t *yyctx)
+{
+ enum { YYARGS_MAX = 5 };
+ /* Internationalized format string. */
+ const char *yyformat = YY_NULLPTR;
+ /* Arguments of yyformat: reported tokens (one for the "unexpected",
+ one per "expected"). */
+ yysymbol_kind_t yyarg[YYARGS_MAX];
+ /* Cumulated lengths of YYARG. */
+ YYPTRDIFF_T yysize = 0;
+
+ /* Actual size of YYARG. */
+ int yycount = yy_syntax_error_arguments (yyctx, yyarg, YYARGS_MAX);
+ if (yycount == YYENOMEM)
+ return YYENOMEM;
+
+ switch (yycount)
+ {
+#define YYCASE_(N, S) \
+ case N: \
+ yyformat = S; \
+ break
+ default: /* Avoid compiler warnings. */
+ YYCASE_(0, YY_("syntax error"));
+ YYCASE_(1, YY_("syntax error, unexpected %s"));
+ YYCASE_(2, YY_("syntax error, unexpected %s, expecting %s"));
+ YYCASE_(3, YY_("syntax error, unexpected %s, expecting %s or %s"));
+ YYCASE_(4, YY_("syntax error, unexpected %s, expecting %s or %s or %s"));
+ YYCASE_(5, YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s"));
+#undef YYCASE_
+ }
+
+ /* Compute error message size. Don't count the "%s"s, but reserve
+ room for the terminator. */
+ yysize = yystrlen (yyformat) - 2 * yycount + 1;
+ {
+ int yyi;
+ for (yyi = 0; yyi < yycount; ++yyi)
+ {
+ YYPTRDIFF_T yysize1
+ = yysize + yytnamerr (YY_NULLPTR, yytname[yyarg[yyi]]);
+ if (yysize <= yysize1 && yysize1 <= YYSTACK_ALLOC_MAXIMUM)
+ yysize = yysize1;
+ else
+ return YYENOMEM;
+ }
+ }
+
+ if (*yymsg_alloc < yysize)
+ {
+ *yymsg_alloc = 2 * yysize;
+ if (! (yysize <= *yymsg_alloc
+ && *yymsg_alloc <= YYSTACK_ALLOC_MAXIMUM))
+ *yymsg_alloc = YYSTACK_ALLOC_MAXIMUM;
+ return -1;
+ }
+
+ /* Avoid sprintf, as that infringes on the user's name space.
+ Don't have undefined behavior even if the translation
+ produced a string with the wrong number of "%s"s. */
+ {
+ char *yyp = *yymsg;
+ int yyi = 0;
+ while ((*yyp = *yyformat) != '\0')
+ if (*yyp == '%' && yyformat[1] == 's' && yyi < yycount)
+ {
+ yyp += yytnamerr (yyp, yytname[yyarg[yyi++]]);
+ yyformat += 2;
+ }
+ else
+ {
+ ++yyp;
+ ++yyformat;
+ }
+ }
+ return 0;
+}
+
+
+/*-----------------------------------------------.
+| Release the memory associated to this symbol. |
+`-----------------------------------------------*/
+
+static void
+yydestruct (const char *yymsg,
+ yysymbol_kind_t yykind, YYSTYPE *yyvaluep, YYLTYPE *yylocationp, struct term **term, yyscan_t scanner)
+{
+ YY_USE (yyvaluep);
+ YY_USE (yylocationp);
+ YY_USE (term);
+ YY_USE (scanner);
+ 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 (struct term **term, yyscan_t scanner)
+{
+/* 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];
+
+ /* Buffer for error messages, and its allocated size. */
+ char yymsgbuf[128];
+ char *yymsg = yymsgbuf;
+ YYPTRDIFF_T yymsg_alloc = sizeof yymsgbuf;
+
+#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. */
+
+
+/* User initialization code. */
+#line 66 "parser.y"
+{
+ yylloc.first_line = 1;
+ yylloc.first_column = 0;
+ yylloc.last_line = 1;
+ yylloc.last_column = 0;
+ yylloc.filename = augl_get_info(scanner)->filename;
+ yylloc.error = augl_get_info(scanner)->error;
+}
+
+#line 1633 "parser.c"
+
+ 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, scanner);
+ }
+
+ 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 2: /* start: KW_MODULE UIDENT '=' autoload decls */
+#line 180 "parser.y"
+ { (*term) = make_module((yyvsp[-3].string), (yyvsp[-1].string), (yyvsp[0].term), &(yylsp[-4])); }
+#line 1846 "parser.c"
+ break;
+
+ case 3: /* autoload: KW_AUTOLOAD LIDENT */
+#line 183 "parser.y"
+ { (yyval.string) = (yyvsp[0].string); }
+#line 1852 "parser.c"
+ break;
+
+ case 4: /* autoload: %empty */
+#line 185 "parser.y"
+ { (yyval.string) = NULL; }
+#line 1858 "parser.c"
+ break;
+
+ case 5: /* decls: KW_LET LIDENT param_list '=' exp decls */
+#line 188 "parser.y"
+ {
+ LOC_MERGE((yylsp[-5]), (yylsp[-5]), (yylsp[-1]));
+ (yyval.term) = make_bind((yyvsp[-4].string), (yyvsp[-3].term), (yyvsp[-1].term), (yyvsp[0].term), &(yylsp[-5]));
+ }
+#line 1867 "parser.c"
+ break;
+
+ case 6: /* decls: KW_LET_REC LIDENT '=' exp decls */
+#line 193 "parser.y"
+ {
+ LOC_MERGE((yylsp[-4]), (yylsp[-4]), (yylsp[-1]));
+ (yyval.term) = make_bind_rec((yyvsp[-3].string), (yyvsp[-1].term), (yyvsp[0].term), &(yylsp[-4]));
+ }
+#line 1876 "parser.c"
+ break;
+
+ case 7: /* decls: KW_TEST test_exp '=' exp decls */
+#line 198 "parser.y"
+ {
+ LOC_MERGE((yylsp[-4]), (yylsp[-4]), (yylsp[-1]));
+ (yyval.term) = make_test((yyvsp[-3].term), (yyvsp[-1].term), TR_CHECK, (yyvsp[0].term), &(yylsp[-4]));
+ }
+#line 1885 "parser.c"
+ break;
+
+ case 8: /* decls: KW_TEST test_exp '=' test_special_res decls */
+#line 203 "parser.y"
+ {
+ LOC_MERGE((yylsp[-4]), (yylsp[-4]), (yylsp[-1]));
+ (yyval.term) = make_test((yyvsp[-3].term), NULL, (yyvsp[-1].intval), (yyvsp[0].term), &(yylsp[-4]));
+ }
+#line 1894 "parser.c"
+ break;
+
+ case 9: /* decls: %empty */
+#line 208 "parser.y"
+ { (yyval.term) = NULL; }
+#line 1900 "parser.c"
+ break;
+
+ case 10: /* test_exp: aexp KW_GET exp */
+#line 213 "parser.y"
+ { (yyval.term) = make_get_test((yyvsp[-2].term), (yyvsp[0].term), &(yyloc)); }
+#line 1906 "parser.c"
+ break;
+
+ case 11: /* test_exp: aexp KW_PUT aexp KW_AFTER exp */
+#line 215 "parser.y"
+ { (yyval.term) = make_put_test((yyvsp[-4].term), (yyvsp[-2].term), (yyvsp[0].term), &(yyloc)); }
+#line 1912 "parser.c"
+ break;
+
+ case 12: /* test_special_res: '?' */
+#line 218 "parser.y"
+ { (yyval.intval) = TR_PRINT; }
+#line 1918 "parser.c"
+ break;
+
+ case 13: /* test_special_res: '*' */
+#line 220 "parser.y"
+ { (yyval.intval) = TR_EXN; }
+#line 1924 "parser.c"
+ break;
+
+ case 14: /* exp: KW_LET LIDENT param_list '=' exp KW_IN exp */
+#line 224 "parser.y"
+ {
+ LOC_MERGE((yylsp[-6]), (yylsp[-6]), (yylsp[-1]));
+ (yyval.term) = make_let((yyvsp[-5].string), (yyvsp[-4].term), (yyvsp[-2].term), (yyvsp[0].term), &(yylsp[-6]));
+ }
+#line 1933 "parser.c"
+ break;
+
+ case 16: /* composeexp: composeexp ';' unionexp */
+#line 231 "parser.y"
+ { (yyval.term) = make_binop(A_COMPOSE, (yyvsp[-2].term), (yyvsp[0].term), &(yyloc)); }
+#line 1939 "parser.c"
+ break;
+
+ case 17: /* composeexp: unionexp */
+#line 233 "parser.y"
+ { (yyval.term) = (yyvsp[0].term); }
+#line 1945 "parser.c"
+ break;
+
+ case 18: /* unionexp: unionexp '|' minusexp */
+#line 236 "parser.y"
+ { (yyval.term) = make_binop(A_UNION, (yyvsp[-2].term), (yyvsp[0].term), &(yyloc)); }
+#line 1951 "parser.c"
+ break;
+
+ case 19: /* unionexp: minusexp */
+#line 238 "parser.y"
+ { (yyval.term) = (yyvsp[0].term); }
+#line 1957 "parser.c"
+ break;
+
+ case 20: /* unionexp: tree_const */
+#line 240 "parser.y"
+ { (yyval.term) = make_tree_value((yyvsp[0].tree), &(yylsp[0])); }
+#line 1963 "parser.c"
+ break;
+
+ case 21: /* minusexp: minusexp '-' catexp */
+#line 243 "parser.y"
+ { (yyval.term) = make_binop(A_MINUS, (yyvsp[-2].term), (yyvsp[0].term), &(yyloc)); }
+#line 1969 "parser.c"
+ break;
+
+ case 22: /* minusexp: catexp */
+#line 245 "parser.y"
+ { (yyval.term) = (yyvsp[0].term); }
+#line 1975 "parser.c"
+ break;
+
+ case 23: /* catexp: catexp '.' appexp */
+#line 248 "parser.y"
+{ (yyval.term) = make_binop(A_CONCAT, (yyvsp[-2].term), (yyvsp[0].term), &(yyloc)); }
+#line 1981 "parser.c"
+ break;
+
+ case 24: /* catexp: appexp */
+#line 250 "parser.y"
+{ (yyval.term) = (yyvsp[0].term); }
+#line 1987 "parser.c"
+ break;
+
+ case 25: /* appexp: appexp rexp */
+#line 253 "parser.y"
+ { (yyval.term) = make_binop(A_APP, (yyvsp[-1].term), (yyvsp[0].term), &(yyloc)); }
+#line 1993 "parser.c"
+ break;
+
+ case 26: /* appexp: rexp */
+#line 255 "parser.y"
+ { (yyval.term) = (yyvsp[0].term); }
+#line 1999 "parser.c"
+ break;
+
+ case 27: /* aexp: qid */
+#line 258 "parser.y"
+ { (yyval.term) = make_ident((yyvsp[0].string), &(yylsp[0])); }
+#line 2005 "parser.c"
+ break;
+
+ case 28: /* aexp: DQUOTED */
+#line 260 "parser.y"
+ { (yyval.term) = make_string_term((yyvsp[0].string), &(yylsp[0])); }
+#line 2011 "parser.c"
+ break;
+
+ case 29: /* aexp: REGEXP */
+#line 262 "parser.y"
+ { (yyval.term) = make_regexp_term((yyvsp[0].regexp).pattern, (yyvsp[0].regexp).nocase, &(yylsp[0])); }
+#line 2017 "parser.c"
+ break;
+
+ case 30: /* aexp: '(' exp ')' */
+#line 264 "parser.y"
+ { (yyval.term) = (yyvsp[-1].term); }
+#line 2023 "parser.c"
+ break;
+
+ case 31: /* aexp: '[' exp ']' */
+#line 266 "parser.y"
+ { (yyval.term) = make_unop(A_BRACKET, (yyvsp[-1].term), &(yyloc)); }
+#line 2029 "parser.c"
+ break;
+
+ case 32: /* aexp: '(' ')' */
+#line 268 "parser.y"
+ { (yyval.term) = make_unit_term(&(yyloc)); }
+#line 2035 "parser.c"
+ break;
+
+ case 33: /* rexp: aexp rep */
+#line 271 "parser.y"
+ { (yyval.term) = make_rep((yyvsp[-1].term), (yyvsp[0].quant), &(yyloc)); }
+#line 2041 "parser.c"
+ break;
+
+ case 34: /* rexp: aexp */
+#line 273 "parser.y"
+ { (yyval.term) = (yyvsp[0].term); }
+#line 2047 "parser.c"
+ break;
+
+ case 35: /* rep: '*' */
+#line 276 "parser.y"
+ { (yyval.quant) = Q_STAR; }
+#line 2053 "parser.c"
+ break;
+
+ case 36: /* rep: '+' */
+#line 278 "parser.y"
+ { (yyval.quant) = Q_PLUS; }
+#line 2059 "parser.c"
+ break;
+
+ case 37: /* rep: '?' */
+#line 280 "parser.y"
+ { (yyval.quant) = Q_MAYBE; }
+#line 2065 "parser.c"
+ break;
+
+ case 38: /* qid: LIDENT */
+#line 283 "parser.y"
+ { (yyval.string) = (yyvsp[0].string); }
+#line 2071 "parser.c"
+ break;
+
+ case 39: /* qid: QIDENT */
+#line 285 "parser.y"
+ { (yyval.string) = (yyvsp[0].string); }
+#line 2077 "parser.c"
+ break;
+
+ case 40: /* qid: KW_GET */
+#line 287 "parser.y"
+ { (yyval.string) = strdup("get"); }
+#line 2083 "parser.c"
+ break;
+
+ case 41: /* qid: KW_PUT */
+#line 289 "parser.y"
+ { (yyval.string) = strdup("put"); }
+#line 2089 "parser.c"
+ break;
+
+ case 42: /* param_list: param param_list */
+#line 292 "parser.y"
+ { (yyval.term) = (yyvsp[0].term); list_cons((yyval.term), (yyvsp[-1].term)); }
+#line 2095 "parser.c"
+ break;
+
+ case 43: /* param_list: %empty */
+#line 294 "parser.y"
+ { (yyval.term) = NULL; }
+#line 2101 "parser.c"
+ break;
+
+ case 44: /* param: '(' id ':' type ')' */
+#line 297 "parser.y"
+ { (yyval.term) = make_param((yyvsp[-3].string), (yyvsp[-1].type), clone_info(&(yylsp[-4]))); }
+#line 2107 "parser.c"
+ break;
+
+ case 45: /* id: LIDENT */
+#line 300 "parser.y"
+ { (yyval.string) = (yyvsp[0].string); }
+#line 2113 "parser.c"
+ break;
+
+ case 46: /* id: KW_GET */
+#line 302 "parser.y"
+ { (yyval.string) = strdup("get"); }
+#line 2119 "parser.c"
+ break;
+
+ case 47: /* id: KW_PUT */
+#line 304 "parser.y"
+ { (yyval.string) = strdup("put"); }
+#line 2125 "parser.c"
+ break;
+
+ case 48: /* type: atype ARROW type */
+#line 307 "parser.y"
+ { (yyval.type) = make_arrow_type((yyvsp[-2].type), (yyvsp[0].type)); }
+#line 2131 "parser.c"
+ break;
+
+ case 49: /* type: atype */
+#line 309 "parser.y"
+ { (yyval.type) = (yyvsp[0].type); }
+#line 2137 "parser.c"
+ break;
+
+ case 50: /* atype: KW_STRING */
+#line 312 "parser.y"
+ { (yyval.type) = make_base_type(T_STRING); }
+#line 2143 "parser.c"
+ break;
+
+ case 51: /* atype: KW_REGEXP */
+#line 314 "parser.y"
+ { (yyval.type) = make_base_type(T_REGEXP); }
+#line 2149 "parser.c"
+ break;
+
+ case 52: /* atype: KW_LENS */
+#line 316 "parser.y"
+ { (yyval.type) = make_base_type(T_LENS); }
+#line 2155 "parser.c"
+ break;
+
+ case 53: /* atype: '(' type ')' */
+#line 318 "parser.y"
+ { (yyval.type) = (yyvsp[-1].type); }
+#line 2161 "parser.c"
+ break;
+
+ case 54: /* tree_const: tree_const '{' tree_branch '}' */
+#line 321 "parser.y"
+ { (yyval.tree) = tree_concat((yyvsp[-3].tree), (yyvsp[-1].tree)); }
+#line 2167 "parser.c"
+ break;
+
+ case 55: /* tree_const: '{' tree_branch '}' */
+#line 323 "parser.y"
+ { (yyval.tree) = tree_concat((yyvsp[-1].tree), NULL); }
+#line 2173 "parser.c"
+ break;
+
+ case 56: /* tree_const2: tree_const2 '{' tree_branch '}' */
+#line 326 "parser.y"
+ {
+ (yyval.tree) = tree_concat((yyvsp[-3].tree), (yyvsp[-1].tree));
+ }
+#line 2181 "parser.c"
+ break;
+
+ case 57: /* tree_const2: %empty */
+#line 330 "parser.y"
+ { (yyval.tree) = NULL; }
+#line 2187 "parser.c"
+ break;
+
+ case 58: /* tree_branch: tree_label tree_const2 */
+#line 333 "parser.y"
+ {
+ (yyval.tree) = make_tree((yyvsp[-1].string), NULL, NULL, (yyvsp[0].tree));
+ }
+#line 2195 "parser.c"
+ break;
+
+ case 59: /* tree_branch: tree_label '=' DQUOTED tree_const2 */
+#line 337 "parser.y"
+ {
+ (yyval.tree) = make_tree((yyvsp[-3].string), (yyvsp[-1].string), NULL, (yyvsp[0].tree));
+ }
+#line 2203 "parser.c"
+ break;
+
+ case 61: /* tree_label: %empty */
+#line 342 "parser.y"
+ { (yyval.string) = NULL; }
+#line 2209 "parser.c"
+ break;
+
+
+#line 2213 "parser.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;
+ {
+ yypcontext_t yyctx
+ = {yyssp, yytoken, &yylloc};
+ char const *yymsgp = YY_("syntax error");
+ int yysyntax_error_status;
+ yysyntax_error_status = yysyntax_error (&yymsg_alloc, &yymsg, &yyctx);
+ if (yysyntax_error_status == 0)
+ yymsgp = yymsg;
+ else if (yysyntax_error_status == -1)
+ {
+ if (yymsg != yymsgbuf)
+ YYSTACK_FREE (yymsg);
+ yymsg = YY_CAST (char *,
+ YYSTACK_ALLOC (YY_CAST (YYSIZE_T, yymsg_alloc)));
+ if (yymsg)
+ {
+ yysyntax_error_status
+ = yysyntax_error (&yymsg_alloc, &yymsg, &yyctx);
+ yymsgp = yymsg;
+ }
+ else
+ {
+ yymsg = yymsgbuf;
+ yymsg_alloc = sizeof yymsgbuf;
+ yysyntax_error_status = YYENOMEM;
+ }
+ }
+ yyerror (&yylloc, term, scanner, yymsgp);
+ if (yysyntax_error_status == YYENOMEM)
+ YYNOMEM;
+ }
+ }
+
+ 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, term, scanner);
+ 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, term, scanner);
+ 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, term, scanner, 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, term, scanner);
+ }
+ /* 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, term, scanner);
+ YYPOPSTACK (1);
+ }
+#ifndef yyoverflow
+ if (yyss != yyssa)
+ YYSTACK_FREE (yyss);
+#endif
+ if (yymsg != yymsgbuf)
+ YYSTACK_FREE (yymsg);
+ return yyresult;
+}
+
+#line 343 "parser.y"
+
+
+int augl_parse_file(struct augeas *aug, const char *name,
+ struct term **term) {
+ yyscan_t scanner;
+ struct state state;
+ struct string *sname = NULL;
+ struct info info;
+ int result = -1;
+ int r;
+
+ *term = NULL;
+
+ r = make_ref(sname);
+ ERR_NOMEM(r < 0, aug);
+
+ sname->str = strdup(name);
+ ERR_NOMEM(sname->str == NULL, aug);
+
+ MEMZERO(&info, 1);
+ info.ref = UINT_MAX;
+ info.filename = sname;
+ info.error = aug->error;
+
+ MEMZERO(&state, 1);
+ state.info = &info;
+ state.comment_depth = 0;
+
+ if (augl_init_lexer(&state, &scanner) < 0) {
+ augl_error(&info, term, NULL, "file not found");
+ goto error;
+ }
+
+ yydebug = getenv("YYDEBUG") != NULL;
+ r = augl_parse(term, scanner);
+ augl_close_lexer(scanner);
+ augl_lex_destroy(scanner);
+ if (r == 1) {
+ augl_error(&info, term, NULL, "syntax error");
+ goto error;
+ } else if (r == 2) {
+ augl_error(&info, term, NULL, "parser ran out of memory");
+ ERR_NOMEM(1, aug);
+ }
+ result = 0;
+
+ error:
+ unref(sname, string);
+ // free TERM
+ return result;
+}
+
+// FIXME: Nothing here checks for alloc errors.
+static struct info *clone_info(struct info *locp) {
+ struct info *info;
+ make_ref(info);
+ info->filename = ref(locp->filename);
+ info->first_line = locp->first_line;
+ info->first_column = locp->first_column;
+ info->last_line = locp->last_line;
+ info->last_column = locp->last_column;
+ info->error = locp->error;
+ return info;
+}
+
+static struct term *make_term_locp(enum term_tag tag, struct info *locp) {
+ struct info *info = clone_info(locp);
+ return make_term(tag, info);
+}
+
+static struct term *make_module(char *ident, char *autoload,
+ struct term *decls,
+ struct info *locp) {
+ struct term *term = make_term_locp(A_MODULE, locp);
+ term->mname = ident;
+ term->autoload = autoload;
+ term->decls = decls;
+ return term;
+}
+
+static struct term *make_bind(char *ident, struct term *params,
+ struct term *exp, struct term *decls,
+ struct info *locp) {
+ struct term *term = make_term_locp(A_BIND, locp);
+ if (params != NULL)
+ exp = build_func(params, exp);
+
+ term->bname = ident;
+ term->exp = exp;
+ list_cons(decls, term);
+ return decls;
+}
+
+static struct term *make_bind_rec(char *ident, struct term *exp,
+ struct term *decls, struct info *locp) {
+ /* Desugar let rec IDENT = EXP as
+ * let IDENT =
+ * let RLENS = (lns_make_rec) in
+ * lns_check_rec ((lambda IDENT: EXP) RLENS) RLENS
+ * where RLENS is a brandnew recursive lens.
+ *
+ * That only works since we know that 'let rec' is only defined for lenses,
+ * not general purposes functions, i.e. we know that IDENT has type 'lens'
+ *
+ * The point of all this is that we make it possible to put a recursive
+ * lens (which is a placeholder for the actual recursion) into arbitrary
+ * places in some bigger lens and then have LNS_CHECK_REC rattle through
+ * to do the special-purpose typechecking.
+ */
+ char *id;
+ struct info *info = exp->info;
+ struct term *lambda = NULL, *rlens = NULL;
+ struct term *app1 = NULL, *app2 = NULL, *app3 = NULL;
+
+ id = strdup(ident);
+ if (id == NULL) goto error;
+
+ lambda = make_param(id, make_base_type(T_LENS), ref(info));
+ if (lambda == NULL) goto error;
+ id = NULL;
+
+ build_func(lambda, exp);
+
+ rlens = make_term(A_VALUE, ref(exp->info));
+ if (rlens == NULL) goto error;
+ rlens->value = lns_make_rec(ref(exp->info));
+ if (rlens->value == NULL) goto error;
+ rlens->type = make_base_type(T_LENS);
+
+ app1 = make_app_term(lambda, rlens, ref(info));
+ if (app1 == NULL) goto error;
+
+ id = strdup(LNS_CHECK_REC_NAME);
+ if (id == NULL) goto error;
+ app2 = make_app_ident(id, app1, ref(info));
+ if (app2 == NULL) goto error;
+ id = NULL;
+
+ app3 = make_app_term(app2, ref(rlens), ref(info));
+ if (app3 == NULL) goto error;
+
+ return make_bind(ident, NULL, app3, decls, locp);
+
+ error:
+ free(id);
+ unref(lambda, term);
+ unref(rlens, term);
+ unref(app1, term);
+ unref(app2, term);
+ unref(app3, term);
+ return NULL;
+}
+
+static struct term *make_let(char *ident, struct term *params,
+ struct term *exp, struct term *body,
+ struct info *locp) {
+ /* let f (x:string) = "f " . x in
+ f "a" . f "b" */
+ /* (lambda f: f "a" . f "b") (lambda x: "f " . x) */
+ /* (lambda IDENT: BODY) (lambda PARAMS: EXP) */
+ /* Desugar as (lambda IDENT: BODY) (lambda PARAMS: EXP) */
+ struct term *term = make_term_locp(A_LET, locp);
+ struct term *p = make_param(ident, NULL, ref(term->info));
+ term->left = build_func(p, body);
+ if (params != NULL)
+ term->right = build_func(params, exp);
+ else
+ term->right = exp;
+ return term;
+}
+
+static struct term *make_binop(enum term_tag tag,
+ struct term *left, struct term *right,
+ struct info *locp) {
+ assert(tag == A_COMPOSE || tag == A_CONCAT
+ || tag == A_UNION || tag == A_APP || tag == A_MINUS);
+ struct term *term = make_term_locp(tag, locp);
+ term->left = left;
+ term->right = right;
+ return term;
+}
+
+static struct term *make_unop(enum term_tag tag, struct term *exp,
+ struct info *locp) {
+ assert(tag == A_BRACKET);
+ struct term *term = make_term_locp(tag, locp);
+ term->brexp = exp;
+ return term;
+}
+
+static struct term *make_ident(char *qname, struct info *locp) {
+ struct term *term = make_term_locp(A_IDENT, locp);
+ term->ident = make_string(qname);
+ return term;
+}
+
+static struct term *make_unit_term(struct info *locp) {
+ struct term *term = make_term_locp(A_VALUE, locp);
+ term->value = make_unit(ref(term->info));
+ return term;
+}
+
+static struct term *make_string_term(char *value, struct info *locp) {
+ struct term *term = make_term_locp(A_VALUE, locp);
+ term->value = make_value(V_STRING, ref(term->info));
+ term->value->string = make_string(value);
+ return term;
+}
+
+static struct term *make_regexp_term(char *pattern, int nocase,
+ struct info *locp) {
+ struct term *term = make_term_locp(A_VALUE, locp);
+ term->value = make_value(V_REGEXP, ref(term->info));
+ term->value->regexp = make_regexp(term->info, pattern, nocase);
+ return term;
+}
+
+static struct term *make_rep(struct term *exp, enum quant_tag quant,
+ struct info *locp) {
+ struct term *term = make_term_locp(A_REP, locp);
+ term->quant = quant;
+ term->exp = exp;
+ return term;
+}
+
+static struct term *make_get_test(struct term *lens, struct term *arg,
+ struct info *locp) {
+ /* Return a term for "get" LENS ARG */
+ struct info *info = clone_info(locp);
+ struct term *term = make_app_ident(strdup("get"), lens, info);
+ term = make_app_term(term, arg, ref(info));
+ return term;
+}
+
+static struct term *make_put_test(struct term *lens, struct term *arg,
+ struct term *cmds, struct info *locp) {
+ /* Return a term for "put" LENS (CMDS ("get" LENS ARG)) ARG */
+ struct term *term = make_get_test(lens, arg, locp);
+ term = make_app_term(cmds, term, ref(term->info));
+ struct term *put = make_app_ident(strdup("put"), ref(lens), ref(term->info));
+ put = make_app_term(put, term, ref(term->info));
+ put = make_app_term(put, ref(arg), ref(term->info));
+ return put;
+}
+
+static struct term *make_test(struct term *test, struct term *result,
+ enum test_result_tag tr_tag,
+ struct term *decls, struct info *locp) {
+ struct term *term = make_term_locp(A_TEST, locp);
+ term->tr_tag = tr_tag;
+ term->test = test;
+ term->result = result;
+ term->next = decls;
+ return term;
+}
+
+static struct term *make_tree_value(struct tree *tree, struct info *locp) {
+ struct term *term = make_term_locp(A_VALUE, locp);
+ struct value *value = make_value(V_TREE, ref(term->info));
+ value->origin = make_tree_origin(tree);
+ term->value = value;
+ return term;
+}
+
+static struct tree *tree_concat(struct tree *t1, struct tree *t2) {
+ if (t2 != NULL)
+ list_append(t1, t2);
+ return t1;
+}
+
+void augl_error(struct info *locp,
+ struct term **term,
+ yyscan_t scanner,
+ const char *s) {
+ struct info info;
+ struct string string;
+ MEMZERO(&info, 1);
+ info.ref = string.ref = UINT_MAX;
+ info.filename = &string;
+
+ if (locp != NULL) {
+ info.first_line = locp->first_line;
+ info.first_column = locp->first_column;
+ info.last_line = locp->last_line;
+ info.last_column = locp->last_column;
+ info.filename->str = locp->filename->str;
+ info.error = locp->error;
+ } else if (scanner != NULL) {
+ info.first_line = augl_get_lineno(scanner);
+ info.first_column = augl_get_column(scanner);
+ info.last_line = augl_get_lineno(scanner);
+ info.last_column = augl_get_column(scanner);
+ info.filename = augl_get_info(scanner)->filename;
+ info.error = augl_get_info(scanner)->error;
+ } else if (*term != NULL && (*term)->info != NULL) {
+ memcpy(&info, (*term)->info, sizeof(info));
+ } else {
+ info.first_line = info.last_line = 0;
+ info.first_column = info.last_column = 0;
+ }
+ syntax_error(&info, "%s", s);
+}
diff --git a/libraries/cmake/source/augeas/generated/macos/aarch64/code/parser.h b/libraries/cmake/source/augeas/generated/macos/aarch64/code/parser.h
new file mode 100644
index 00000000000..f4f7d5ed91e
--- /dev/null
+++ b/libraries/cmake/source/augeas/generated/macos/aarch64/code/parser.h
@@ -0,0 +1,161 @@
+/* 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_AUGL_PARSER_H_INCLUDED
+# define YY_AUGL_PARSER_H_INCLUDED
+/* Debug traces. */
+#ifndef YYDEBUG
+# define YYDEBUG 0
+#endif
+#if YYDEBUG
+extern int augl_debug;
+#endif
+
+/* Token kinds. */
+#ifndef YYTOKENTYPE
+# define YYTOKENTYPE
+ enum yytokentype
+ {
+ YYEMPTY = -2,
+ YYEOF = 0, /* "end of file" */
+ YYerror = 256, /* error */
+ YYUNDEF = 257, /* "invalid token" */
+ DQUOTED = 258, /* DQUOTED */
+ REGEXP = 259, /* REGEXP */
+ LIDENT = 260, /* LIDENT */
+ UIDENT = 261, /* UIDENT */
+ QIDENT = 262, /* QIDENT */
+ ARROW = 263, /* ARROW */
+ KW_MODULE = 264, /* KW_MODULE */
+ KW_AUTOLOAD = 265, /* KW_AUTOLOAD */
+ KW_LET = 266, /* KW_LET */
+ KW_LET_REC = 267, /* KW_LET_REC */
+ KW_IN = 268, /* KW_IN */
+ KW_STRING = 269, /* KW_STRING */
+ KW_REGEXP = 270, /* KW_REGEXP */
+ KW_LENS = 271, /* KW_LENS */
+ KW_TEST = 272, /* KW_TEST */
+ KW_GET = 273, /* KW_GET */
+ KW_PUT = 274, /* KW_PUT */
+ KW_AFTER = 275 /* KW_AFTER */
+ };
+ typedef enum yytokentype yytoken_kind_t;
+#endif
+/* Token kinds. */
+#define YYEMPTY -2
+#define YYEOF 0
+#define YYerror 256
+#define YYUNDEF 257
+#define DQUOTED 258
+#define REGEXP 259
+#define LIDENT 260
+#define UIDENT 261
+#define QIDENT 262
+#define ARROW 263
+#define KW_MODULE 264
+#define KW_AUTOLOAD 265
+#define KW_LET 266
+#define KW_LET_REC 267
+#define KW_IN 268
+#define KW_STRING 269
+#define KW_REGEXP 270
+#define KW_LENS 271
+#define KW_TEST 272
+#define KW_GET 273
+#define KW_PUT 274
+#define KW_AFTER 275
+
+/* Value type. */
+#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
+union YYSTYPE
+{
+#line 89 "parser.y"
+
+ struct term *term;
+ struct type *type;
+ struct ident *ident;
+ struct tree *tree;
+ char *string;
+ struct {
+ int nocase;
+ char *pattern;
+ } regexp;
+ int intval;
+ enum quant_tag quant;
+
+#line 121 "parser.h"
+
+};
+typedef union YYSTYPE YYSTYPE;
+# define YYSTYPE_IS_TRIVIAL 1
+# define YYSTYPE_IS_DECLARED 1
+#endif
+
+/* 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 augl_parse (struct term **term, yyscan_t scanner);
+
+/* "%code provides" blocks. */
+#line 46 "parser.y"
+
+#include "info.h"
+
+/* Track custom scanner state */
+struct state {
+ struct info *info;
+ unsigned int comment_depth;
+};
+
+
+#line 160 "parser.h"
+
+#endif /* !YY_AUGL_PARSER_H_INCLUDED */
diff --git a/libraries/cmake/source/augeas/generated/macos/aarch64/config/config.h b/libraries/cmake/source/augeas/generated/macos/aarch64/config/config.h
new file mode 100644
index 00000000000..d92b1dbaa88
--- /dev/null
+++ b/libraries/cmake/source/augeas/generated/macos/aarch64/config/config.h
@@ -0,0 +1,1562 @@
+/* config.h. Generated from config.h.in by configure. */
+/* config.h.in. Generated from configure.ac by autoheader. */
+
+/* Define if building universal (internal helper macro) */
+/* #undef AC_APPLE_UNIVERSAL_BUILD */
+
+/* Define to the number of bits in type 'ptrdiff_t'. */
+/* #undef BITSIZEOF_PTRDIFF_T */
+
+/* Define to the number of bits in type 'sig_atomic_t'. */
+/* #undef BITSIZEOF_SIG_ATOMIC_T */
+
+/* Define to the number of bits in type 'size_t'. */
+/* #undef BITSIZEOF_SIZE_T */
+
+/* Define to the number of bits in type 'wchar_t'. */
+/* #undef BITSIZEOF_WCHAR_T */
+
+/* Define to the number of bits in type 'wint_t'. */
+/* #undef BITSIZEOF_WINT_T */
+
+/* Define to 1 if using 'alloca.c'. */
+/* #undef C_ALLOCA */
+
+/* Define to 1 if the C locale may have encoding errors. */
+#define C_LOCALE_MAYBE_EILSEQ 1
+
+/* Define as the bit index in the word where to find bit 0 of the exponent of
+ 'double'. */
+#define DBL_EXPBIT0_BIT 20
+
+/* Define as the word index where to find the exponent of 'double'. */
+#define DBL_EXPBIT0_WORD 1
+
+/* Define to 1 if // is a file system root distinct from /. */
+/* #undef DOUBLE_SLASH_IS_DISTINCT_ROOT */
+
+/* whether debugging is enabled */
+#define ENABLE_DEBUG 1
+
+/* Define this to 1 if F_DUPFD behavior does not match POSIX */
+/* #undef FCNTL_DUPFD_BUGGY */
+
+/* Define to nothing if C supports flexible array members, and to 1 if it does
+ not. That way, with a declaration like 'struct s { int n; double
+ d[FLEXIBLE_ARRAY_MEMBER]; };', the struct hack can be used with pre-C99
+ compilers. When computing the size of such an object, don't use 'sizeof
+ (struct s)' as it overestimates the size. Use 'offsetof (struct s, d)'
+ instead. Don't use 'offsetof (struct s, d[0])', as this doesn't work with
+ MSVC and with C++ compilers. */
+#define FLEXIBLE_ARRAY_MEMBER /**/
+
+/* Enable compile-time and run-time bounds-checking, and some warnings,
+ without upsetting newer glibc. */
+ #if !defined _FORTIFY_SOURCE && defined __OPTIMIZE__ && __OPTIMIZE__
+ # define _FORTIFY_SOURCE 2
+ #endif
+
+
+/* Define to 1 if mkdir mistakenly creates a directory given with a trailing
+ dot component. */
+#define FUNC_MKDIR_DOT_BUG 1
+
+/* Define to 1 if nl_langinfo (YESEXPR) returns a non-empty string. */
+#define FUNC_NL_LANGINFO_YESEXPR_WORKS 1
+
+/* Define to 1 if realpath() can malloc memory, always gives an absolute path,
+ and handles trailing slash correctly. */
+/* #undef FUNC_REALPATH_WORKS */
+
+/* Define if gettimeofday clobbers the localtime buffer. */
+#define GETTIMEOFDAY_CLOBBERS_LOCALTIME 1
+
+/* Define this to 'void' or 'struct timezone' to match the system's
+ declaration of the second argument to gettimeofday. */
+#define GETTIMEOFDAY_TIMEZONE void
+
+/* Define to a C preprocessor expression that evaluates to 1 or 0, depending
+ whether the gnulib module canonicalize-lgpl shall be considered present. */
+#define GNULIB_CANONICALIZE_LGPL 1
+
+/* Define to a C preprocessor expression that evaluates to 1 or 0, depending
+ whether the gnulib module fscanf shall be considered present. */
+#define GNULIB_FSCANF 1
+
+/* Define to a C preprocessor expression that evaluates to 1 or 0, depending
+ whether the gnulib module lock shall be considered present. */
+#define GNULIB_LOCK 1
+
+/* Define to a C preprocessor expression that evaluates to 1 or 0, depending
+ whether the gnulib module msvc-nothrow shall be considered present. */
+#define GNULIB_MSVC_NOTHROW IN_AUGEAS_GNULIB_TESTS
+
+/* Define to 1 if printf and friends should be labeled with attribute
+ "__gnu_printf__" instead of "__printf__" */
+/* #undef GNULIB_PRINTF_ATTRIBUTE_FLAVOR_GNU */
+
+/* Define to a C preprocessor expression that evaluates to 1 or 0, depending
+ whether the gnulib module scanf shall be considered present. */
+#define GNULIB_SCANF 1
+
+/* Define to a C preprocessor expression that evaluates to 1 or 0, depending
+ whether the gnulib module strerror shall be considered present. */
+#define GNULIB_STRERROR IN_AUGEAS_GNULIB_TESTS
+
+/* Define to a C preprocessor expression that evaluates to 1 or 0, depending
+ whether the gnulib module strerror_r-posix shall be considered present. */
+#define GNULIB_STRERROR_R_POSIX IN_AUGEAS_GNULIB_TESTS
+
+/* Define to 1 when the gnulib module accept should be tested. */
+#define GNULIB_TEST_ACCEPT 1
+
+/* Define to 1 when the gnulib module bind should be tested. */
+#define GNULIB_TEST_BIND 1
+
+/* Define to 1 when the gnulib module btowc should be tested. */
+#define GNULIB_TEST_BTOWC 1
+
+/* Define to 1 when the gnulib module canonicalize_file_name should be tested.
+ */
+#define GNULIB_TEST_CANONICALIZE_FILE_NAME 1
+
+/* Define to 1 when the gnulib module cloexec should be tested. */
+#define GNULIB_TEST_CLOEXEC 1
+
+/* Define to 1 when the gnulib module close should be tested. */
+#define GNULIB_TEST_CLOSE 1
+
+/* Define to 1 when the gnulib module connect should be tested. */
+#define GNULIB_TEST_CONNECT 1
+
+/* Define to 1 when the gnulib module dup2 should be tested. */
+#define GNULIB_TEST_DUP2 1
+
+/* Define to 1 when the gnulib module environ should be tested. */
+#define GNULIB_TEST_ENVIRON 1
+
+/* Define to 1 when the gnulib module fcntl should be tested. */
+#define GNULIB_TEST_FCNTL 1
+
+/* Define to 1 when the gnulib module fdopen should be tested. */
+#define GNULIB_TEST_FDOPEN 1
+
+/* Define to 1 when the gnulib module fnmatch should be tested. */
+#define GNULIB_TEST_FNMATCH 1
+
+/* Define to 1 when the gnulib module fstat should be tested. */
+#define GNULIB_TEST_FSTAT 1
+
+/* Define to 1 when the gnulib module ftruncate should be tested. */
+#define GNULIB_TEST_FTRUNCATE 1
+
+/* Define to 1 when the gnulib module getcwd should be tested. */
+#define GNULIB_TEST_GETCWD 1
+
+/* Define to 1 when the gnulib module getdelim should be tested. */
+#define GNULIB_TEST_GETDELIM 1
+
+/* Define to 1 when the gnulib module getdtablesize should be tested. */
+#define GNULIB_TEST_GETDTABLESIZE 1
+
+/* Define to 1 when the gnulib module getline should be tested. */
+#define GNULIB_TEST_GETLINE 1
+
+/* Define to 1 when the gnulib module getpagesize should be tested. */
+#define GNULIB_TEST_GETPAGESIZE 1
+
+/* Define to 1 when the gnulib module gettimeofday should be tested. */
+#define GNULIB_TEST_GETTIMEOFDAY 1
+
+/* Define to 1 when the gnulib module ioctl should be tested. */
+#define GNULIB_TEST_IOCTL 1
+
+/* Define to 1 when the gnulib module listen should be tested. */
+#define GNULIB_TEST_LISTEN 1
+
+/* Define to 1 when the gnulib module localeconv should be tested. */
+#define GNULIB_TEST_LOCALECONV 1
+
+/* Define to 1 when the gnulib module localename should be tested. */
+#define GNULIB_TEST_LOCALENAME 1
+
+/* Define to 1 when the gnulib module lstat should be tested. */
+#define GNULIB_TEST_LSTAT 1
+
+/* Define to 1 when the gnulib module malloc-posix should be tested. */
+#define GNULIB_TEST_MALLOC_POSIX 1
+
+/* Define to 1 when the gnulib module mbrtowc should be tested. */
+#define GNULIB_TEST_MBRTOWC 1
+
+/* Define to 1 when the gnulib module mbsinit should be tested. */
+#define GNULIB_TEST_MBSINIT 1
+
+/* Define to 1 when the gnulib module mbsrtowcs should be tested. */
+#define GNULIB_TEST_MBSRTOWCS 1
+
+/* Define to 1 when the gnulib module mbtowc should be tested. */
+#define GNULIB_TEST_MBTOWC 1
+
+/* Define to 1 when the gnulib module memchr should be tested. */
+#define GNULIB_TEST_MEMCHR 1
+
+/* Define to 1 when the gnulib module mempcpy should be tested. */
+#define GNULIB_TEST_MEMPCPY 1
+
+/* Define to 1 when the gnulib module mkstemp should be tested. */
+#define GNULIB_TEST_MKSTEMP 1
+
+/* Define to 1 when the gnulib module nanosleep should be tested. */
+#define GNULIB_TEST_NANOSLEEP 1
+
+/* Define to 1 when the gnulib module nl_langinfo should be tested. */
+#define GNULIB_TEST_NL_LANGINFO 1
+
+/* Define to 1 when the gnulib module open should be tested. */
+#define GNULIB_TEST_OPEN 1
+
+/* Define to 1 when the gnulib module perror should be tested. */
+#define GNULIB_TEST_PERROR 1
+
+/* Define to 1 when the gnulib module pipe should be tested. */
+#define GNULIB_TEST_PIPE 1
+
+/* Define to 1 when the gnulib module pthread_sigmask should be tested. */
+#define GNULIB_TEST_PTHREAD_SIGMASK 1
+
+/* Define to 1 when the gnulib module putenv should be tested. */
+#define GNULIB_TEST_PUTENV 1
+
+/* Define to 1 when the gnulib module raise should be tested. */
+#define GNULIB_TEST_RAISE 1
+
+/* Define to 1 when the gnulib module rawmemchr should be tested. */
+#define GNULIB_TEST_RAWMEMCHR 1
+
+/* Define to 1 when the gnulib module readlink should be tested. */
+#define GNULIB_TEST_READLINK 1
+
+/* Define to 1 when the gnulib module realpath should be tested. */
+#define GNULIB_TEST_REALPATH 1
+
+/* Define to 1 when the gnulib module select should be tested. */
+#define GNULIB_TEST_SELECT 1
+
+/* Define to 1 when the gnulib module setenv should be tested. */
+#define GNULIB_TEST_SETENV 1
+
+/* Define to 1 when the gnulib module setlocale should be tested. */
+#define GNULIB_TEST_SETLOCALE 1
+
+/* Define to 1 when the gnulib module setsockopt should be tested. */
+#define GNULIB_TEST_SETSOCKOPT 1
+
+/* Define to 1 when the gnulib module sigaction should be tested. */
+#define GNULIB_TEST_SIGACTION 1
+
+/* Define to 1 when the gnulib module sigprocmask should be tested. */
+#define GNULIB_TEST_SIGPROCMASK 1
+
+/* Define to 1 when the gnulib module sleep should be tested. */
+#define GNULIB_TEST_SLEEP 1
+
+/* Define to 1 when the gnulib module socket should be tested. */
+#define GNULIB_TEST_SOCKET 1
+
+/* Define to 1 when the gnulib module stat should be tested. */
+#define GNULIB_TEST_STAT 1
+
+/* Define to 1 when the gnulib module stpcpy should be tested. */
+#define GNULIB_TEST_STPCPY 1
+
+/* Define to 1 when the gnulib module stpncpy should be tested. */
+#define GNULIB_TEST_STPNCPY 1
+
+/* Define to 1 when the gnulib module strchrnul should be tested. */
+#define GNULIB_TEST_STRCHRNUL 1
+
+/* Define to 1 when the gnulib module strerror should be tested. */
+#define GNULIB_TEST_STRERROR 1
+
+/* Define to 1 when the gnulib module strerror_r should be tested. */
+#define GNULIB_TEST_STRERROR_R 1
+
+/* Define to 1 when the gnulib module strndup should be tested. */
+#define GNULIB_TEST_STRNDUP 1
+
+/* Define to 1 when the gnulib module strnlen should be tested. */
+#define GNULIB_TEST_STRNLEN 1
+
+/* Define to 1 when the gnulib module strstr should be tested. */
+#define GNULIB_TEST_STRSTR 1
+
+/* Define to 1 when the gnulib module symlink should be tested. */
+#define GNULIB_TEST_SYMLINK 1
+
+/* Define to 1 when the gnulib module unsetenv should be tested. */
+#define GNULIB_TEST_UNSETENV 1
+
+/* Define to 1 when the gnulib module usleep should be tested. */
+#define GNULIB_TEST_USLEEP 1
+
+/* Define to 1 when the gnulib module vasprintf should be tested. */
+#define GNULIB_TEST_VASPRINTF 1
+
+/* Define to 1 when the gnulib module wcrtomb should be tested. */
+#define GNULIB_TEST_WCRTOMB 1
+
+/* Define to 1 when the gnulib module wctob should be tested. */
+#define GNULIB_TEST_WCTOB 1
+
+/* Define to 1 when the gnulib module wctomb should be tested. */
+#define GNULIB_TEST_WCTOMB 1
+
+/* Define to 1 if you have 'alloca' after including , a header that
+ may be supplied by this distribution. */
+#define HAVE_ALLOCA 1
+
+/* Define to 1 if works. */
+#define HAVE_ALLOCA_H 1
+
+/* Define to 1 if you have the header file. */
+/* #undef HAVE_ARGZ_H */
+
+/* Define to 1 if you have the header file. */
+#define HAVE_ARPA_INET_H 1
+
+/* Define to 1 if you have the header file. */
+/* #undef HAVE_BP_SYM_H */
+
+/* Define to 1 if you have the `btowc' function. */
+#define HAVE_BTOWC 1
+
+/* Define to 1 if nanosleep mishandles large arguments. */
+/* #undef HAVE_BUG_BIG_NANOSLEEP */
+
+/* Define to 1 if you have the `canonicalize_file_name' function. */
+/* #undef HAVE_CANONICALIZE_FILE_NAME */
+
+/* Define to 1 if you have the `catgets' function. */
+#define HAVE_CATGETS 1
+
+/* Define to 1 if you have the Mac OS X function CFLocaleCopyCurrent in the
+ CoreFoundation framework. */
+#define HAVE_CFLOCALECOPYCURRENT 1
+
+/* Define to 1 if you have the Mac OS X function
+ CFLocaleCopyPreferredLanguages in the CoreFoundation framework. */
+#define HAVE_CFLOCALECOPYPREFERREDLANGUAGES 1
+
+/* Define to 1 if you have the Mac OS X function CFPreferencesCopyAppValue in
+ the CoreFoundation framework. */
+#define HAVE_CFPREFERENCESCOPYAPPVALUE 1
+
+/* Define to 1 if you have the `chsize' function. */
+/* #undef HAVE_CHSIZE */
+
+/* Define to 1 if you have the header file. */
+/* #undef HAVE_CRTDEFS_H */
+
+/* Define to 1 if you have the declaration of `alarm', and to 0 if you don't.
+ */
+#define HAVE_DECL_ALARM 1
+
+/* Define to 1 if you have the declaration of `getc_unlocked', and to 0 if you
+ don't. */
+#define HAVE_DECL_GETC_UNLOCKED 1
+
+/* Define to 1 if you have the declaration of `getdelim', and to 0 if you
+ don't. */
+#define HAVE_DECL_GETDELIM 1
+
+/* Define to 1 if you have the declaration of `getdtablesize', and to 0 if you
+ don't. */
+#define HAVE_DECL_GETDTABLESIZE 1
+
+/* Define to 1 if you have the declaration of `getline', and to 0 if you
+ don't. */
+#define HAVE_DECL_GETLINE 1
+
+/* Define to 1 if you have the declaration of `inet_pton', and to 0 if you
+ don't. */
+#define HAVE_DECL_INET_PTON 1
+
+/* Define to 1 if you have the declaration of `isblank', and to 0 if you
+ don't. */
+#define HAVE_DECL_ISBLANK 1
+
+/* Define to 1 if you have the declaration of `mbrtowc', and to 0 if you
+ don't. */
+/* #undef HAVE_DECL_MBRTOWC */
+
+/* Define to 1 if you have the declaration of `mbsinit', and to 0 if you
+ don't. */
+/* #undef HAVE_DECL_MBSINIT */
+
+/* Define to 1 if you have the declaration of `mbsrtowcs', and to 0 if you
+ don't. */
+/* #undef HAVE_DECL_MBSRTOWCS */
+
+/* Define to 1 if you have the declaration of `setenv', and to 0 if you don't.
+ */
+#define HAVE_DECL_SETENV 1
+
+/* Define to 1 if you have the declaration of `sleep', and to 0 if you don't.
+ */
+#define HAVE_DECL_SLEEP 1
+
+/* Define to 1 if you have the declaration of `stpncpy', and to 0 if you
+ don't. */
+#define HAVE_DECL_STPNCPY 1
+
+/* Define to 1 if you have the declaration of `strerror_r', and to 0 if you
+ don't. */
+#define HAVE_DECL_STRERROR_R 1
+
+/* Define to 1 if you have the declaration of `strndup', and to 0 if you
+ don't. */
+#define HAVE_DECL_STRNDUP 1
+
+/* Define to 1 if you have the declaration of `strnlen', and to 0 if you
+ don't. */
+#define HAVE_DECL_STRNLEN 1
+
+/* Define to 1 if you have the declaration of `towlower', and to 0 if you
+ don't. */
+/* #undef HAVE_DECL_TOWLOWER */
+
+/* Define to 1 if you have the declaration of `unsetenv', and to 0 if you
+ don't. */
+#define HAVE_DECL_UNSETENV 1
+
+/* Define to 1 if you have the declaration of `wcrtomb', and to 0 if you
+ don't. */
+/* #undef HAVE_DECL_WCRTOMB */
+
+/* Define to 1 if you have the declaration of `wctob', and to 0 if you don't.
+ */
+#define HAVE_DECL_WCTOB 1
+
+/* Define to 1 if you have the declaration of `_putenv', and to 0 if you
+ don't. */
+#define HAVE_DECL__PUTENV 0
+
+/* Define to 1 if you have the declaration of `_snprintf', and to 0 if you
+ don't. */
+#define HAVE_DECL__SNPRINTF 0
+
+/* Define to 1 if you have the header file. */
+#define HAVE_DLFCN_H 1
+
+/* Define to 1 if you have the 'dup2' function. */
+#define HAVE_DUP2 1
+
+/* Define to 1 if you have the `duplocale' function. */
+#define HAVE_DUPLOCALE 1
+
+/* Define if you have the declaration of environ. */
+/* #undef HAVE_ENVIRON_DECL */
+
+/* Define to 1 if the system has the type `error_t'. */
+/* #undef HAVE_ERROR_T */
+
+/* Define if the locale_t type contains insufficient information, as on
+ OpenBSD. */
+/* #undef HAVE_FAKE_LOCALES */
+
+/* Define to 1 if you have the `fcntl' function. */
+#define HAVE_FCNTL 1
+
+/* Define to 1 if you have the header file. */
+/* #undef HAVE_FEATURES_H */
+
+/* Define to 1 if you have the `flockfile' function. */
+#define HAVE_FLOCKFILE 1
+
+/* Define to 1 if you have the `fnmatch' function. */
+#define HAVE_FNMATCH 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_FNMATCH_H 1
+
+/* Define to 1 if you have the `freelocale' function. */
+#define HAVE_FREELOCALE 1
+
+/* Define to 1 if you have the `fsync' function. */
+#define HAVE_FSYNC 1
+
+/* Define to 1 if you have the `ftruncate' function. */
+#define HAVE_FTRUNCATE 1
+
+/* Define to 1 if you have the `funlockfile' function. */
+#define HAVE_FUNLOCKFILE 1
+
+/* Define to 1 if you have the `getcwd' function. */
+#define HAVE_GETCWD 1
+
+/* Define to 1 if you have the `getdelim' function. */
+#define HAVE_GETDELIM 1
+
+/* Define to 1 if you have the `getdtablesize' function. */
+#define HAVE_GETDTABLESIZE 1
+
+/* Define to 1 if you have the `getlocalename_l' function. */
+/* #undef HAVE_GETLOCALENAME_L */
+
+/* Define to 1 if you have the header file. */
+#define HAVE_GETOPT_H 1
+
+/* Define to 1 if you have the `getopt_long_only' function. */
+#define HAVE_GETOPT_LONG_ONLY 1
+
+/* Define to 1 if you have the `gettimeofday' function. */
+#define HAVE_GETTIMEOFDAY 1
+
+/* Define to 1 if you have the `inet_pton' function. */
+/* #undef HAVE_INET_PTON */
+
+/* Define if you have the 'intmax_t' type in or . */
+#define HAVE_INTMAX_T 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_INTTYPES_H 1
+
+/* Define if exists, doesn't clash with , and
+ declares uintmax_t. */
+#define HAVE_INTTYPES_H_WITH_UINTMAX 1
+
+/* Define to 1 if you have the `ioctl' function. */
+#define HAVE_IOCTL 1
+
+/* Define to 1 if defines AF_INET. */
+#define HAVE_IPV4 1
+
+/* Define to 1 if defines AF_INET6. */
+#define HAVE_IPV6 1
+
+/* Define to 1 if you have the `isblank' function. */
+#define HAVE_ISBLANK 1
+
+/* Define to 1 if you have the `iswcntrl' function. */
+#define HAVE_ISWCNTRL 1
+
+/* Define to 1 if you have the `iswctype' function. */
+#define HAVE_ISWCTYPE 1
+
+/* Define if you have and nl_langinfo(CODESET). */
+#define HAVE_LANGINFO_CODESET 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_LANGINFO_H 1
+
+/* Define if your file defines LC_MESSAGES. */
+#define HAVE_LC_MESSAGES 1
+
+/* Define to 1 if you have the header file. */
+/* #undef HAVE_LIBINTL_H */
+
+/* Define to 1 if you have the header file. */
+#define HAVE_LIMITS_H 1
+
+/* Define to 1 if the system has the type 'long long int'. */
+#define HAVE_LONG_LONG_INT 1
+
+/* Define to 1 if you have the `lstat' function. */
+#define HAVE_LSTAT 1
+
+/* Define to 1 if you have the header file. */
+/* #undef HAVE_MALLOC_H */
+
+/* Define if the 'malloc' function is POSIX compliant. */
+#define HAVE_MALLOC_POSIX 1
+
+/* Define to 1 if mmap()'s MAP_ANONYMOUS flag is available after including
+ config.h and . */
+#define HAVE_MAP_ANONYMOUS 1
+
+/* Define to 1 if you have the `mbrtowc' function. */
+#define HAVE_MBRTOWC 1
+
+/* Define to 1 if you have the `mbsinit' function. */
+#define HAVE_MBSINIT 1
+
+/* Define to 1 if you have the `mbsrtowcs' function. */
+#define HAVE_MBSRTOWCS 1
+
+/* Define to 1 if declares mbstate_t. */
+#define HAVE_MBSTATE_T 1
+
+/* Define to 1 if you have the `mbtowc' function. */
+#define HAVE_MBTOWC 1
+
+/* Define to 1 if you have the `mempcpy' function. */
+/* #undef HAVE_MEMPCPY */
+
+/* Define to 1 if you have the `mkstemp' function. */
+#define HAVE_MKSTEMP 1
+
+/* Define to 1 if you have the `mprotect' function. */
+#define HAVE_MPROTECT 1
+
+/* Define to 1 on MSVC platforms that have the "invalid parameter handler"
+ concept. */
+/* #undef HAVE_MSVC_INVALID_PARAMETER_HANDLER */
+
+/* Define if the locale_t type does not contain the name of each locale
+ category. */
+/* #undef HAVE_NAMELESS_LOCALES */
+
+/* Define to 1 if you have the header file. */
+#define HAVE_NETDB_H 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_NETINET_IN_H 1
+
+/* Define to 1 if you have the `newlocale' function. */
+#define HAVE_NEWLOCALE 1
+
+/* Define to 1 if you have the `nl_langinfo' function. */
+#define HAVE_NL_LANGINFO 1
+
+/* Define to 1 if you have the header file. */
+/* #undef HAVE_OS_H */
+
+/* Define to 1 if you have the `pipe' function. */
+#define HAVE_PIPE 1
+
+/* Define to 1 if you have the `pthread_atfork' function. */
+#define HAVE_PTHREAD_ATFORK 1
+
+/* Define if the defines PTHREAD_MUTEX_RECURSIVE. */
+#define HAVE_PTHREAD_MUTEX_RECURSIVE 1
+
+/* Define if the POSIX multithreading library has read/write locks. */
+#define HAVE_PTHREAD_RWLOCK 1
+
+/* Define if the 'pthread_rwlock_rdlock' function prefers a writer to a
+ reader. */
+#define HAVE_PTHREAD_RWLOCK_RDLOCK_PREFER_WRITER 1
+
+/* Define to 1 if the pthread_sigmask function can be used (despite bugs). */
+#define HAVE_PTHREAD_SIGMASK 1
+
+/* Define to 1 if you have the `raise' function. */
+#define HAVE_RAISE 1
+
+/* Define to 1 if you have the `rawmemchr' function. */
+/* #undef HAVE_RAWMEMCHR */
+
+/* Define to 1 if you have the `readlink' function. */
+#define HAVE_READLINK 1
+
+/* Define to 1 if you have the `realpath' function. */
+#define HAVE_REALPATH 1
+
+/* Define to 1 if the system has the type `sa_family_t'. */
+#define HAVE_SA_FAMILY_T 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_SEARCH_H 1
+
+/* Define to 1 if you have the header file. */
+/* #undef HAVE_SELINUX_CONTEXT_H */
+
+/* Define to 1 if you have the header file. */
+#define HAVE_SELINUX_SELINUX_H 0
+
+/* Define to 1 if you have the header file. */
+#define HAVE_SEMAPHORE_H 1
+
+/* Define to 1 if you have the `setdtablesize' function. */
+/* #undef HAVE_SETDTABLESIZE */
+
+/* Define to 1 if you have the `setenv' function. */
+#define HAVE_SETENV 1
+
+/* Define to 1 if you have the `shutdown' function. */
+#define HAVE_SHUTDOWN 1
+
+/* Define to 1 if you have the `sigaction' function. */
+#define HAVE_SIGACTION 1
+
+/* Define to 1 if you have the `sigaltstack' function. */
+#define HAVE_SIGALTSTACK 1
+
+/* Define to 1 if the system has the type `siginfo_t'. */
+/* #undef HAVE_SIGINFO_T */
+
+/* Define to 1 if you have the `siginterrupt' function. */
+#define HAVE_SIGINTERRUPT 1
+
+/* Define to 1 if 'sig_atomic_t' is a signed integer type. */
+/* #undef HAVE_SIGNED_SIG_ATOMIC_T */
+
+/* Define to 1 if 'wchar_t' is a signed integer type. */
+/* #undef HAVE_SIGNED_WCHAR_T */
+
+/* Define to 1 if 'wint_t' is a signed integer type. */
+/* #undef HAVE_SIGNED_WINT_T */
+
+/* Define to 1 if the system has the type `sigset_t'. */
+#define HAVE_SIGSET_T 1
+
+/* Define to 1 if you have the `sleep' function. */
+#define HAVE_SLEEP 1
+
+/* Define to 1 if you have the `snprintf' function. */
+#define HAVE_SNPRINTF 1
+
+/* Define if the return value of the snprintf function is the number of of
+ bytes (excluding the terminating NUL) that would have been produced if the
+ buffer had been large enough. */
+/* #undef HAVE_SNPRINTF_RETVAL_C99 */
+
+/* Define if the locale_t type is as on Solaris 11.4. */
+/* #undef HAVE_SOLARIS114_LOCALES */
+
+/* Define to 1 if you have the header file. */
+#define HAVE_STDINT_H 1
+
+/* Define if exists, doesn't clash with , and declares
+ uintmax_t. */
+#define HAVE_STDINT_H_WITH_UINTMAX 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_STDIO_H 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_STDLIB_H 1
+
+/* Define to 1 if you have the `stpcpy' function. */
+#define HAVE_STPCPY 1
+
+/* Define if you have the stpncpy() function and it works. */
+#define HAVE_STPNCPY 1
+
+/* Define to 1 if you have the `strchrnul' function. */
+/* #undef HAVE_STRCHRNUL */
+
+/* Define to 1 if you have the `strerror_r' function. */
+#define HAVE_STRERROR_R 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_STRINGS_H 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_STRING_H 1
+
+/* Define to 1 if you have the `strndup' function. */
+#define HAVE_STRNDUP 1
+
+/* Define to 1 if you have the `strnlen' function. */
+#define HAVE_STRNLEN 1
+
+/* Define to 1 if `decimal_point' is a member of `struct lconv'. */
+/* #undef HAVE_STRUCT_LCONV_DECIMAL_POINT */
+
+/* Define to 1 if `sa_sigaction' is a member of `struct sigaction'. */
+#define HAVE_STRUCT_SIGACTION_SA_SIGACTION 1
+
+/* Define to 1 if the system has the type `struct sockaddr_storage'. */
+#define HAVE_STRUCT_SOCKADDR_STORAGE 1
+
+/* Define to 1 if `ss_family' is a member of `struct sockaddr_storage'. */
+#define HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY 1
+
+/* Define to 1 if `st_atimensec' is a member of `struct stat'. */
+/* #undef HAVE_STRUCT_STAT_ST_ATIMENSEC */
+
+/* Define to 1 if `st_atimespec.tv_nsec' is a member of `struct stat'. */
+#define HAVE_STRUCT_STAT_ST_ATIMESPEC_TV_NSEC 1
+
+/* Define to 1 if `st_atim.st__tim.tv_nsec' is a member of `struct stat'. */
+/* #undef HAVE_STRUCT_STAT_ST_ATIM_ST__TIM_TV_NSEC */
+
+/* Define to 1 if `st_atim.tv_nsec' is a member of `struct stat'. */
+/* #undef HAVE_STRUCT_STAT_ST_ATIM_TV_NSEC */
+
+/* Define to 1 if `st_birthtimensec' is a member of `struct stat'. */
+/* #undef HAVE_STRUCT_STAT_ST_BIRTHTIMENSEC */
+
+/* Define to 1 if `st_birthtimespec.tv_nsec' is a member of `struct stat'. */
+#define HAVE_STRUCT_STAT_ST_BIRTHTIMESPEC_TV_NSEC 1
+
+/* Define to 1 if `st_birthtim.tv_nsec' is a member of `struct stat'. */
+/* #undef HAVE_STRUCT_STAT_ST_BIRTHTIM_TV_NSEC */
+
+/* Define to 1 if you have the `symlink' function. */
+#define HAVE_SYMLINK 1
+
+/* Define to 1 if you have the header file. */
+/* #undef HAVE_SYS_BITYPES_H */
+
+/* Define to 1 if you have the header file. */
+#define HAVE_SYS_CDEFS_H 1
+
+/* Define to 1 if you have the header file. */
+/* #undef HAVE_SYS_INTTYPES_H */
+
+/* Define to 1 if you have the header file. */
+#define HAVE_SYS_IOCTL_H 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_SYS_MMAN_H 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_SYS_PARAM_H 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_SYS_SELECT_H 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_SYS_SOCKET_H 1
+
+/* Define to 1 if you have the header file. */
+#define HAVE_SYS_STAT_H 1
+
+/* Define to 1 if you have the